ActionControl<T> class

@{macro action-control}

ActionControl.single - Only one sub can be active. ActionControl.broadcast - Multiple subs can be used. ActionControl.provider - Subscription to BroadcastProvider.

Inheritance
Available Extensions

Properties

hashCode int
The hash code for this object.
no setterinherited
internalData ↔ dynamic
getter/setter pairinherited
isActive bool
no setterinherited
isEmpty bool
no setterinherited
isNotEmpty bool
no setterinherited
isValid bool
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
subCount int
no setterinherited
subs List<ControlSubscription<T>>
finalinherited
value ↔ T
getter/setter pairinherited

Methods

cancel(ControlSubscription<T> subscription) → void
inherited
cast<U>() ObservableValue<U>
inherited
clear() → void
inherited
createSubscription([dynamic args]) ControlSubscription<T>
inherited
dispose() → void
Used to clear and dispose object. After this method call is object typically unusable and ready for GC. Can be called multiple times!
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notify() → void
inherited
pause() → void
inherited
resume() → void
inherited
setValue(T value, {bool notify = true, bool forceNotify = false}) → void
inherited
subscribe(ValueCallback<T> action, {bool current = true, dynamic args}) ControlSubscription<T>
override
toString() String
A string representation of this object.
override

Operators

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

Static Methods

broadcast<T>(T value) ActionControl<T>
Simplified version of Stream to provide basic and lightweight functionality to notify listeners. Multiple subs can be used.
empty<T>({T? value, bool broadcast = true}) ActionControl<T?>
override
provider<T>({dynamic key, T? defaultValue}) ActionControl<T?>
Simplified version of Stream to provide basic and lightweight functionality to notify listeners. This control will subscribe to BroadcastProvider with given key and will listen to Global Stream.
single<T>(T value) ActionControl<T>
Simplified version of Stream to provide basic and lightweight functionality to notify listeners. Only one sub can be active.