@@ -2640,7 +2640,7 @@ class DiagnosticsProperty<T> extends DiagnosticsNode {
26402640 Map <String , Object > toJsonMap (DiagnosticsSerializationDelegate delegate) {
26412641 final T v = value;
26422642 List <Map <String , Object >> properties;
2643- if (delegate.expandPropertyValues && delegate.includeProperties && v is Diagnosticable && getProperties ().isEmpty) {
2643+ if (delegate.expandPropertyValues && delegate.includeProperties && v is DiagnosticableMixin && getProperties ().isEmpty) {
26442644 // Exclude children for expanded nodes to avoid cycles.
26452645 delegate = delegate.copyWith (subtreeDepth: 0 , includeProperties: false );
26462646 properties = DiagnosticsNode .toJsonList (
@@ -2666,7 +2666,7 @@ class DiagnosticsProperty<T> extends DiagnosticsNode {
26662666 json['exception' ] = exception.toString ();
26672667 json['propertyType' ] = propertyType.toString ();
26682668 json['defaultLevel' ] = describeEnum (_defaultLevel);
2669- if (value is Diagnosticable || value is DiagnosticsNode )
2669+ if (value is DiagnosticableMixin || value is DiagnosticsNode )
26702670 json['isDiagnosticableValue' ] = true ;
26712671 if (v is num )
26722672 // Workaround for https://github.com/flutter/flutter/issues/39937#issuecomment-529558033.
@@ -2846,7 +2846,7 @@ class DiagnosticsProperty<T> extends DiagnosticsNode {
28462846 if (object is DiagnosticsNode ) {
28472847 return object.getProperties ();
28482848 }
2849- if (object is Diagnosticable ) {
2849+ if (object is DiagnosticableMixin ) {
28502850 return object.toDiagnosticsNode (style: style).getProperties ();
28512851 }
28522852 }
@@ -2860,7 +2860,7 @@ class DiagnosticsProperty<T> extends DiagnosticsNode {
28602860 if (object is DiagnosticsNode ) {
28612861 return object.getChildren ();
28622862 }
2863- if (object is Diagnosticable ) {
2863+ if (object is DiagnosticableMixin ) {
28642864 return object.toDiagnosticsNode (style: style).getChildren ();
28652865 }
28662866 }
@@ -2870,8 +2870,8 @@ class DiagnosticsProperty<T> extends DiagnosticsNode {
28702870
28712871/// [DiagnosticsNode] that lazily calls the associated [Diagnosticable] [value]
28722872/// to implement [getChildren] and [getProperties] .
2873- class DiagnosticableNode <T extends Diagnosticable > extends DiagnosticsNode {
2874- /// Create a diagnostics describing a [Diagnosticable ] value.
2873+ class DiagnosticableNode <T extends DiagnosticableMixin > extends DiagnosticsNode {
2874+ /// Create a diagnostics describing a [DiagnosticableMixin ] value.
28752875 ///
28762876 /// The [value] argument must not be null.
28772877 DiagnosticableNode ({
@@ -2991,7 +2991,7 @@ String describeEnum(Object enumEntry) {
29912991}
29922992
29932993/// Builder to accumulate properties and configuration used to assemble a
2994- /// [DiagnosticsNode] from a [Diagnosticable ] object.
2994+ /// [DiagnosticsNode] from a [DiagnosticableMixin ] object.
29952995class DiagnosticPropertiesBuilder {
29962996 /// Creates a [DiagnosticPropertiesBuilder] with [properties] initialize to
29972997 /// an empty array.
@@ -3053,10 +3053,8 @@ abstract class Diagnosticable with DiagnosticableMixin {
30533053 const Diagnosticable ();
30543054}
30553055
3056- /// A mixin class that provides the implementation for [Diagnosticable] .
3057- ///
3058- /// This mixin can be used to add diagnostics to a class which already has an
3059- /// base class.
3056+ /// A mixin class for providing string and [DiagnosticsNode] debug
3057+ /// representations describing the properties of an object.
30603058///
30613059/// The string debug representation is generated from the intermediate
30623060/// [DiagnosticsNode] representation. The [DiagnosticsNode] representation is
@@ -3108,9 +3106,9 @@ mixin DiagnosticableMixin {
31083106 /// relationship between the parent and the node. For example, pass
31093107 /// [DiagnosticsTreeStyle.offstage] to indicate that a node is offstage.
31103108 DiagnosticsNode toDiagnosticsNode ({ String name, DiagnosticsTreeStyle style }) {
3111- return DiagnosticableNode <Diagnosticable >(
3109+ return DiagnosticableNode <DiagnosticableMixin >(
31123110 name: name,
3113- value: this as Diagnosticable ,
3111+ value: this ,
31143112 style: style,
31153113 );
31163114 }
@@ -3338,8 +3336,8 @@ mixin DiagnosticableMixin {
33383336/// See also:
33393337///
33403338/// * [DiagnosticableTreeMixin] , a mixin that implements this class.
3341- /// * [Diagnosticable ] , which should be used instead of this class to provide
3342- /// diagnostics for objects without children.
3339+ /// * [DiagnosticableMixin ] , which should be used instead of this class to
3340+ /// provide diagnostics for objects without children.
33433341abstract class DiagnosticableTree extends Diagnosticable {
33443342 /// Abstract const constructor. This constructor enables subclasses to provide
33453343 /// const constructors so that they can be used in const expressions.
@@ -3643,7 +3641,7 @@ abstract class DiagnosticsSerializationDelegate {
36433641 /// will be included.
36443642 bool get includeProperties;
36453643
3646- /// Whether properties that have a [Diagnosticable ] as value should be
3644+ /// Whether properties that have a [DiagnosticableMixin ] as value should be
36473645 /// expanded.
36483646 bool get expandPropertyValues;
36493647
0 commit comments