Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(32)

Unified Diff: runtime/observatory/lib/src/models/objects/instance.dart

Issue 2212253002: Converted Observatory class-tree element (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Removed tmp code Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: runtime/observatory/lib/src/models/objects/instance.dart
diff --git a/runtime/observatory/lib/src/models/objects/instance.dart b/runtime/observatory/lib/src/models/objects/instance.dart
index e6ee284dc2ee1991375f00b6de1331a6a53cbc73..eb65ea5ae23d113ad4159f80a7a30fe7418fdae8 100644
--- a/runtime/observatory/lib/src/models/objects/instance.dart
+++ b/runtime/observatory/lib/src/models/objects/instance.dart
@@ -4,4 +4,78 @@
part of models;
-abstract class InstanceRef extends ObjectRef {}
+abstract class InstanceRef extends ObjectRef {
+ /// Instance references always include their class.
+ ClassRef get clazz;
+
+ /// [optional] The value of this instance as a string.
+ ///
+ /// Provided for the instance kinds:
+ /// Null (null)
+ /// Bool (true or false)
+ /// Double (suitable for passing to Double.parse())
+ /// Int (suitable for passing to int.parse())
+ /// String (value may be truncated)
+ /// Float32x4
+ /// Float64x2
+ /// Int32x4
+ /// StackTrace
+ String get valueAsString;
+
+ /// [optional] The valueAsString for String references may be truncated. If so,
+ /// this property is added with the value 'true'.
+ ///
+ /// New code should use 'length' and 'count' instead.
+ bool get valueAsStringIsTruncated;
+
+ /// [optional] The length of a List or the number of associations in a Map or
+ /// the number of codeunits in a String.
+ ///
+ /// Provided for instance kinds:
+ /// String
+ /// List
+ /// Map
+ /// Uint8ClampedList
+ /// Uint8List
+ /// Uint16List
+ /// Uint32List
+ /// Uint64List
+ /// Int8List
+ /// Int16List
+ /// Int32List
+ /// Int64List
+ /// Float32List
+ /// Float64List
+ /// Int32x4List
+ /// Float32x4List
+ /// Float64x2List
+ int get length;
+
+ /// [optional] The name of a Type instance.
+ ///
+ /// Provided for instance kinds:
+ /// Type
+ String get name;
+
+ /// [optional] The corresponding Class if this Type is canonical.
+ ///
+ /// Provided for instance kinds:
+ /// Type
+ ClassRef get typeClass;
+
+ /// [optional] The parameterized class of a type parameter:
+ ///
+ /// Provided for instance kinds:
+ /// TypeParameter
+ ClassRef get parameterizedClass;
+
+ /// [optional] The pattern of a RegExp instance.
+ ///
+ /// The pattern is always an instance of kind String.
+ ///
+ /// Provided for instance kinds:
+ /// RegExp
+ InstanceRef get pattern;
+}
+
+abstract class Instance extends Object implements InstanceRef {}
« no previous file with comments | « runtime/observatory/lib/src/models/objects/class.dart ('k') | runtime/observatory/lib/src/models/repositories/class.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698