TransformCancelToken class final

Cooperative cancellation for a long-running transform.

Deliberately not dio's CancelToken — this package must not depend on an HTTP client. id is the key slice 2 sends with the cancel channel method, so the native side can address one in-flight export among several queued.

Constructors

TransformCancelToken()
Creates a fresh, uncancelled token with a process-unique id.

Properties

hashCode → int
The hash code for this object.
no setterinherited
id → String
Process-unique identifier, sent to the platform with cancel.
final
isCancelled → bool
Whether cancel has been called.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
whenCancelled → Future<void>
Completes when cancel is called; never completes otherwise.
no setter

Methods

cancel() → void
Requests cancellation. Idempotent — calling it twice is not an error.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

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

Static Methods

debugResetIdCounter() → void
Resets the id counter so tests can assert on exact ids.