debugFillProperties method Null safety

  1. @override
void debugFillProperties(
  1. DiagnosticPropertiesBuilder description
)
override

Accumulates a list of strings describing the object's state. Subclasses should override this to have their information included in toString.

Implementation

@override
void debugFillProperties(DiagnosticPropertiesBuilder description) {
  super.debugFillProperties(description);
  description.add(DiagnosticsProperty<ImageInfo>('current', _currentImage, ifNull: 'unresolved', showName: false));
  description.add(ObjectFlagProperty<List<ImageStreamListener>>(
    'listeners',
    _listeners,
    ifPresent: '${_listeners.length} listener${_listeners.length == 1 ? "" : "s" }',
  ));
  description.add(FlagProperty('disposed', value: _disposed, ifTrue: '<disposed>'));
}