DVMutableLifecycleSignal<T> class
The framework-facing half of a lifecycle signal.
Kept separate from DVLifecycleSignal so that handing a signal to application code hands over no way to drive it.
- Implemented types
Constructors
- DVMutableLifecycleSignal(T initial)
Properties
-
changes
→ Stream<
T> -
Emits on every transition. Does not replay the current value; read
value for that.
no setteroverride
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- value → T
-
The current state.
no setteroverride
Methods
-
dispose(
) → Future< void> -
listen(
FutureOr< void> onState(T state)) → StreamSubscription<T> -
Observes transitions. Returns a subscription the caller can cancel.
override
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
read(
) → T -
The current state. Provided so reads look the same as elsewhere in
Dartvel, where signals are read with
.read().override -
set(
T next) → void - Advances the state. Re-emitting the same state is a no-op, so observers only ever see genuine transitions.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited