PushStreamWithValue<T> class

StreamWithValue implementation that creates a Stream from subsequent calls to add. This way, value is always set to the latest value that has been added, regardless of whether the updates are listened to (in contrast to StreamWithLatestValue).

Implemented types
Available Extensions

Properties

hashCode int
The hash code for this object.
no setterinherited
loaded bool
Whether it's safe to access value (i.e. it is initialized).
no setteroverride
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
updates Stream<T>
Any changes to value, in the form of a stream. The current value itself typically is not sent upon Stream.listen to updates, although this detail is implementation defined.
no setteroverride
value → T
Must check loaded before attempting to read value. If the value is not initialized (either through withInitialValue or stream event), an exception will be thrown.
no setteroverride

Methods

add(T data) → void
Push data to the stream and save it in value.
override
addError(Object error, [StackTrace? stackTrace]) → void
Adds an error to the sink.
override
close() Future<void>
Close the stream. After that, calls to add are no longer allowed.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited