CancellableOperation<T> class
Result wrapper that includes both the result future and a cancellation token.
This allows you to cancel the operation if needed.
Constructors
-
CancellableOperation({required Future<
T> result, required CancellationToken cancellationToken})
Properties
- cancellationToken → CancellationToken
-
The cancellation token that can be used to cancel this operation.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
result
→ Future<
T> -
The future that will complete with the operation result.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
cancel(
) → void - Cancel this operation.
-
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