ButtonController<T> class
The controller class for the FutureDebounceX widget.
Constructors
-
ButtonController({FDBState initialState = FDBState.disabled, bool enabled = false, void onStateChange(FDBState)?, required Future<
T> onPressed(), void onSuccess(T value)?, dynamic onError(dynamic error, dynamic stackTrace)?, dynamic onAbort()?, Duration? abortStateDuration, Duration? errorStateDuration, Duration? successStateDuration, required Duration debounceDuration, Duration? timeout, required State<StatefulWidget> obj})
Properties
- abortCanBePressed ↔ bool
-
The flag indicating that the button can be pressed to cancel the future.
getter/setter pair
- abortStateDuration → Duration?
-
final
- canAbort → bool
-
The flag indicating that the button can be pressed to cancel the future.
no setter
- debounceDuration → Duration
-
final
- enabled ↔ bool
-
getter/setter pair
- errorStateDuration → Duration?
-
final
-
future
↔ Future<
void> ? -
The reference to the controlled future
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- isAbortable → bool
-
no setter
- newState ← FDBState
-
no getter
-
obj
↔ State<
StatefulWidget> -
The reference to the controlled object
getter/setter pair
- onAbort → dynamic Function()?
-
final
- onAbortPressed → void Function()?
-
no setter
- onActionPressed → void Function()?
-
no setter
- onError → dynamic Function(dynamic error, dynamic stackTrace)?
-
final
-
onPressed
→ Future<
T> Function() -
final
- onStateChange → void Function(FDBState)?
-
final
- onSuccess → void Function(T value)?
-
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
state
↔ Stream<
FDBState> -
latefinal
- successStateDuration → Duration?
-
final
- timeout → Duration?
-
final
Methods
-
dispose(
) → void - Disposes the controller
-
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