EffectCommands class final
Creates EffectCommand0 and EffectCommand instances bound to one long-lived Runtime.
A ViewModel normally receives this capability instead of receiving the Runtime, Module, injector, or every repository it might use.
Constructors
- EffectCommands(Runtime _runtime, {EffectCommandObserver? observer, EffectCommandPolicyObserver? policyObserver})
-
const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- observer → EffectCommandObserver?
-
Optional state-transition observer shared by every created Command.
final
- policyObserver → EffectCommandPolicyObserver?
-
Optional policy-decision observer shared by every created Command.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
call<
A extends Object, E extends Object> (Effect< A, E> action(), {CommandPolicy? policy, EffectCommandConcurrency? concurrency, bool keepPreviousData = true, String? debugLabel, VoidCallback? onCancel, EffectCommandStateObserver<A, E> ? stateObserver, EffectCommandPolicyObserver? policyObserver}) → EffectCommand0<A, E> - Create a command without input.
-
fromEffect<
A extends Object, E extends Object> (Effect< A, E> effect, {CommandPolicy? policy, EffectCommandConcurrency? concurrency, bool keepPreviousData = true, String? debugLabel, VoidCallback? onCancel, EffectCommandStateObserver<A, E> ? stateObserver, EffectCommandPolicyObserver? policyObserver}) → EffectCommand0<A, E> - Create a command from an already-declared Effect.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
withInput<
I, A extends Object, E extends Object> (Effect< A, E> action(I input), {CommandPolicy? policy, EffectCommandConcurrency? concurrency, bool keepPreviousData = true, String? debugLabel, VoidCallback? onCancel, EffectCommandStateObserver<A, E> ? stateObserver, EffectCommandPolicyObserver? policyObserver}) → EffectCommand<I, A, E> - Create a command with one typed input.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited