本文整理匯總了C#中Mono.Debugging.Client.ObjectValue.GetAllChildren方法的典型用法代碼示例。如果您正苦於以下問題:C# ObjectValue.GetAllChildren方法的具體用法?C# ObjectValue.GetAllChildren怎麽用?C# ObjectValue.GetAllChildren使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Mono.Debugging.Client.ObjectValue
的用法示例。
在下文中一共展示了ObjectValue.GetAllChildren方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: CreateVariable
private Variable CreateVariable(ObjectValue v)
{
var pname = String.Format("{0} {1}", v.TypeName, v.Name);
return new Variable(pname, v.DisplayValue, v.HasChildren ? _variableHandles.Create(v.GetAllChildren()) : 0);
}
示例2: PrintValue
void PrintValue (ObjectValue val)
{
string result = val.Value;
if (string.IsNullOrEmpty (result) || val.IsError || val.IsUnknown || val.IsNotSupported) {
view.WriteOutput (GetErrorText (val));
FinishPrinting ();
} else {
var ops = GetEvaluationOptions ();
var children = val.GetAllChildren (ops);
var hasMore = false;
view.WriteOutput (result);
if (children.Length > 0 && string.Equals (children[0].Name, "[0..99]")) {
// Big Arrays Hack
children = children[0].GetAllChildren ();
hasMore = true;
}
var evaluating = new Dictionary<ObjectValue, bool> ();
foreach (var child in children) {
if (child.IsEvaluating) {
evaluating.Add (child, false);
} else {
PrintChildValue (child);
}
}
if (evaluating.Count > 0) {
foreach (var eval in evaluating)
WaitChildForCompleted (eval.Key, evaluating, hasMore);
} else {
FinishPrinting (hasMore);
}
}
}