Exemple #1
0
        static void WriteTo(ITextColorWriter output, ClassifiedTextCollection coll, string unknownText = UNKNOWN)
        {
            if (coll.IsDefault)
            {
                output.Write(BoxedTextColor.Error, unknownText);
                return;
            }

            coll.WriteTo(output);
        }
Exemple #2
0
 public CachedRawNode(bool canEvaluateExpression, string expression, string imageName, bool?hasChildren, ulong?childCount, ClassifiedTextCollection cachedName, ClassifiedTextCollection cachedValue, ClassifiedTextCollection cachedExpectedType, ClassifiedTextCollection cachedActualType)
 {
     CanEvaluateExpression = canEvaluateExpression;
     Expression            = expression ?? throw new ArgumentNullException(nameof(expression));
     ImageName             = imageName ?? throw new ArgumentNullException(nameof(imageName));
     HasChildren           = hasChildren;
     this.childCount       = childCount;
     CachedName            = cachedName;
     CachedValue           = cachedValue;
     CachedExpectedType    = cachedExpectedType;
     CachedActualType      = cachedActualType.IsDefault ? cachedExpectedType : cachedActualType;
 }