key property

Object? key

Returns an object which can be used with == to determine if this PictureStream shares the same listeners list as another PictureStream.

This can be used to avoid unregistering and reregistering listeners after calling PictureProvider.resolve on a new, but possibly equivalent, PictureProvider.

The key may change once in the lifetime of the object. When it changes, it will go from being different than other PictureStream's keys to potentially being the same as others'. No notification is sent when this happens.

Implementation

Object? get key => _completer != null ? _completer : this;