本文整理汇总了C#中IObjectValueSource类的典型用法代码示例。如果您正苦于以下问题:C# IObjectValueSource类的具体用法?C# IObjectValueSource怎么用?C# IObjectValueSource使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IObjectValueSource类属于命名空间,在下文中一共展示了IObjectValueSource类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。
示例1: Create
static ObjectValue Create (IObjectValueSource source, ObjectPath path, string typeName)
{
ObjectValue ob = new ObjectValue ();
ob.source = source;
ob.path = path;
ob.typeName = typeName;
return ob;
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:8,代码来源:ObjectValue.cs
示例2: Create
static ObjectValue Create (IObjectValueSource source, ObjectPath path, string typeName)
{
var val = new ObjectValue ();
val.typeName = typeName;
val.source = source;
val.path = path;
return val;
}
开发者ID:transformersprimeabcxyz,项目名称:debugger-libs,代码行数:8,代码来源:ObjectValue.cs
示例3: CreateObjectValue
public ObjectValue CreateObjectValue (EvaluationContext ctx, IObjectValueSource source, ObjectPath path, object obj, ObjectValueFlags flags)
{
try {
return CreateObjectValueImpl (ctx, source, path, obj, flags);
} catch (Exception ex) {
ctx.WriteDebuggerError (ex);
return ObjectValue.CreateFatalError (path.LastName, ex.Message, flags);
}
}
开发者ID:head-thrash,项目名称:monodevelop,代码行数:9,代码来源:ObjectValueAdaptor.cs
示例4: CreateObject
public static ObjectValue CreateObject (IObjectValueSource source, ObjectPath path, string typeName, EvaluationResult value, ObjectValueFlags flags, ObjectValue[] children)
{
ObjectValue ob = Create (source, path, typeName);
ob.path = path;
ob.flags = flags | ObjectValueFlags.Object;
ob.value = value.Value;
ob.displayValue = value.DisplayValue;
if (children != null) {
ob.children = new List<ObjectValue> ();
ob.children.AddRange (children);
}
return ob;
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:13,代码来源:ObjectValue.cs
示例5: CreatePrimitive
public static ObjectValue CreatePrimitive (IObjectValueSource source, ObjectPath path, string typeName, EvaluationResult value, ObjectValueFlags flags)
{
ObjectValue ob = Create (source, path, typeName);
ob.flags = flags | ObjectValueFlags.Primitive;
ob.value = value.Value;
ob.displayValue = value.DisplayValue;
return ob;
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:8,代码来源:ObjectValue.cs
示例6: CreateNotSupported
public static ObjectValue CreateNotSupported (IObjectValueSource source, ObjectPath path, string typeName, string message, ObjectValueFlags flags)
{
ObjectValue ob = Create (source, path, typeName);
ob.flags = flags | ObjectValueFlags.NotSupported;
ob.value = message;
return ob;
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:7,代码来源:ObjectValue.cs
示例7: CreateEvaluationException
public static ObjectValue CreateEvaluationException(EvaluationContext ctx, IObjectValueSource source, ObjectPath path, EvaluatorExceptionThrownException exception,
ObjectValueFlags flags = ObjectValueFlags.None)
{
var error = CreateError (source, path, exception.ExceptionTypeName, "Exception was thrown", flags);
var exceptionReference = LiteralValueReference.CreateTargetObjectLiteral (ctx, "Exception", exception.Exception);
var exceptionValue = exceptionReference.CreateObjectValue (ctx.Options);
error.children = new List<ObjectValue> {exceptionValue};
return error;
}
开发者ID:nerzhulart,项目名称:debugger-libs,代码行数:9,代码来源:ObjectValue.cs
示例8: CreateError
public static ObjectValue CreateError (IObjectValueSource source, ObjectPath path, string typeName, string value, ObjectValueFlags flags)
{
ObjectValue ob = Create (source, path, typeName);
ob.flags = flags | ObjectValueFlags.Error;
ob.value = value;
return ob;
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:7,代码来源:ObjectValue.cs
示例9: CreateImplicitNotSupported
public static ObjectValue CreateImplicitNotSupported (IObjectValueSource source, ObjectPath path, string typeName, ObjectValueFlags flags)
{
return CreateNotSupported (source, path, typeName, "Implicit evaluation is disabled", flags);
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:4,代码来源:ObjectValue.cs
示例10: CreateNotSupported
public static ObjectValue CreateNotSupported(IObjectValueSource source, ObjectPath path, string typeName, string message, ObjectValueFlags flags)
{
var val = Create (source, path, typeName);
val.flags = flags | ObjectValueFlags.NotSupported;
val.value = message;
return val;
}
开发者ID:nerzhulart,项目名称:debugger-libs,代码行数:7,代码来源:ObjectValue.cs
示例11: CreateError
public static ObjectValue CreateError(IObjectValueSource source, ObjectPath path, string typeName, string value, ObjectValueFlags flags)
{
var val = Create (source, path, typeName);
val.flags = flags | ObjectValueFlags.Error;
val.value = value;
return val;
}
开发者ID:nerzhulart,项目名称:debugger-libs,代码行数:7,代码来源:ObjectValue.cs
示例12: CreateNullObject
public static ObjectValue CreateNullObject (IObjectValueSource source, string name, string typeName, ObjectValueFlags flags)
{
ObjectValue ob = Create (source, new ObjectPath (name), typeName);
ob.flags = flags | ObjectValueFlags.Object;
ob.value = "(null)";
return ob;
}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:7,代码来源:ObjectValue.cs
示例13: CreateNullObject
public static ObjectValue CreateNullObject (IObjectValueSource source, string name, string typeName, ObjectValueFlags flags)
{
return CreateNullObject (source, new ObjectPath (name), typeName, flags);
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:4,代码来源:ObjectValue.cs
示例14: MtaObjectValueSource
public MtaObjectValueSource (IObjectValueSource s)
{
source = s;
}
开发者ID:mono,项目名称:monodevelop,代码行数:4,代码来源:MtaObjectValueSource.cs
示例15: CreateObjectValueImpl
protected override ObjectValue CreateObjectValueImpl (EvaluationContext gctx, IObjectValueSource source, ObjectPath path, object vobj, ObjectValueFlags flags)
{
MdbEvaluationContext ctx = (MdbEvaluationContext) gctx;
TargetObject obj = ctx.GetRealObject (vobj);
if (obj == null)
return ObjectValue.CreateObject (null, path, "", "", flags | ObjectValueFlags.ReadOnly, null);
if (obj.HasAddress && obj.GetAddress (ctx.Thread).IsNull)
return ObjectValue.CreateObject (null, path, obj.TypeName, ctx.Evaluator.ToExpression (ctx, null), flags, null);
switch (obj.Kind) {
case TargetObjectKind.Struct:
case TargetObjectKind.GenericInstance:
case TargetObjectKind.Class:
case TargetObjectKind.Array:
case TargetObjectKind.Fundamental:
case TargetObjectKind.Enum:
return base.CreateObjectValueImpl (gctx, source, path, vobj, flags);
case TargetObjectKind.Object:
TargetObjectObject oob = obj as TargetObjectObject;
if (oob == null)
return ObjectValue.CreateUnknown (path.LastName);
else
return ObjectValue.CreateObject (source, path, obj.TypeName, Server.Instance.Evaluator.TargetObjectToExpression (ctx, obj), flags, null);
case TargetObjectKind.Pointer:
return ObjectValue.CreateObject (source, path, obj.TypeName, Server.Instance.Evaluator.TargetObjectToExpression (ctx, obj), flags, null);
case TargetObjectKind.Nullable:
TargetNullableObject tn = (TargetNullableObject) obj;
if (tn.HasValue (ctx.Thread)) {
ObjectValue val = CreateObjectValue (ctx, source, path, tn.GetValue (ctx.Thread), flags);
val.TypeName = obj.TypeName;
return val;
}
else {
flags |= ObjectValueFlags.Primitive;
return ObjectValue.CreateObject (source, path, obj.TypeName, ctx.Evaluator.ToExpression (ctx, null), flags, new ObjectValue [0]);
}
default:
return ObjectValue.CreateFatalError (path.LastName, "Unknown value type: " + obj.Kind, flags);
}
}
开发者ID:nickname100,项目名称:monodevelop,代码行数:46,代码来源:MdbObjectValueAdaptor.cs
示例16: CreateObjectValueImpl
protected virtual ObjectValue CreateObjectValueImpl(EvaluationContext ctx, IObjectValueSource source, ObjectPath path, object obj, ObjectValueFlags flags)
{
object type = obj != null ? GetValueType (ctx, obj) : null;
string typeName = type != null ? GetTypeName (ctx, type) : "";
if (obj == null || IsNull (ctx, obj))
return ObjectValue.CreateNullObject (source, path, GetDisplayTypeName (typeName), flags);
if (IsPrimitive (ctx, obj) || IsEnum (ctx,obj))
return ObjectValue.CreatePrimitive (source, path, GetDisplayTypeName (typeName), ctx.Evaluator.TargetObjectToExpression (ctx, obj), flags);
if (IsArray (ctx, obj))
return ObjectValue.CreateObject (source, path, GetDisplayTypeName (typeName), ctx.Evaluator.TargetObjectToExpression (ctx, obj), flags, null);
EvaluationResult tvalue = null;
TypeDisplayData tdata = null;
string tname;
if (IsNullableType (ctx, type)) {
if (NullableHasValue (ctx, type, obj)) {
ValueReference value = NullableGetValue (ctx, type, obj);
tdata = GetTypeDisplayData (ctx, value.Type);
obj = value.Value;
} else {
tdata = GetTypeDisplayData (ctx, type);
tvalue = new EvaluationResult ("null");
}
tname = GetDisplayTypeName (typeName);
} else {
tdata = GetTypeDisplayData (ctx, type);
if (!string.IsNullOrEmpty (tdata.TypeDisplayString) && ctx.Options.AllowDisplayStringEvaluation)
tname = EvaluateDisplayString (ctx, obj, tdata.TypeDisplayString);
else
tname = GetDisplayTypeName (typeName);
}
if (tvalue == null) {
if (!string.IsNullOrEmpty (tdata.ValueDisplayString) && ctx.Options.AllowDisplayStringEvaluation)
tvalue = new EvaluationResult (EvaluateDisplayString (ctx, obj, tdata.ValueDisplayString));
else
tvalue = ctx.Evaluator.TargetObjectToExpression (ctx, obj);
}
ObjectValue oval = ObjectValue.CreateObject (source, path, tname, tvalue, flags, null);
if (!string.IsNullOrEmpty (tdata.NameDisplayString) && ctx.Options.AllowDisplayStringEvaluation)
oval.Name = EvaluateDisplayString (ctx, obj, tdata.NameDisplayString);
return oval;
}
开发者ID:hippiehunter,项目名称:debugger-libs,代码行数:52,代码来源:ObjectValueAdaptor.cs
示例17: CreateUnknown
public static ObjectValue CreateUnknown(IObjectValueSource source, ObjectPath path, string typeName)
{
var val = Create (source, path, typeName);
val.flags = ObjectValueFlags.Unknown | ObjectValueFlags.ReadOnly;
return val;
}
开发者ID:nerzhulart,项目名称:debugger-libs,代码行数:6,代码来源:ObjectValue.cs
示例18: CreateNullObject
public static ObjectValue CreateNullObject(IObjectValueSource source, ObjectPath path, string typeName, ObjectValueFlags flags)
{
var val = Create (source, path, typeName);
val.flags = flags | ObjectValueFlags.Object;
val.value = "(null)";
val.isNull = true;
return val;
}
开发者ID:nerzhulart,项目名称:debugger-libs,代码行数:8,代码来源:ObjectValue.cs
示例19: CreateArray
public static ObjectValue CreateArray (IObjectValueSource source, ObjectPath path, string typeName, int arrayCount, ObjectValueFlags flags, ObjectValue[] children)
{
ObjectValue ob = Create (source, path, typeName);
ob.arrayCount = arrayCount;
ob.flags = flags | ObjectValueFlags.Array;
ob.value = "[" + arrayCount + "]";
if (children != null && children.Length > 0) {
ob.children = new List<ObjectValue> ();
ob.children.AddRange (children);
}
return ob;
}
开发者ID:RainsSoft,项目名称:playscript-monodevelop,代码行数:12,代码来源:ObjectValue.cs
示例20: MonoDSymbolResolver
public MonoDSymbolResolver(IObjectValueSource objectValueSource, DEW.DBGEngine engine)
{
this.ObjectValueSource = objectValueSource;
this.Engine = engine;
}
开发者ID:Kentorix,项目名称:monodevelop-win32-debugger,代码行数:5,代码来源:MonoDSymbolResolver.cs
注:本文中的IObjectValueSource类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论