Struct
CancellationToken
struct CancellationToken
Module: System.Concurrency
Assembly: System.Runtime.dll
Source file: Cancellation.rvn
Inheritance: Object → ValueType → CancellationToken
A copyable request-observation capability, independent of any task or scheduler.
Constructors
1 item
CancellationToken()
Creates a token that never requests cancellation.
Properties
3 items
CanBeCancelled: bool
Whether this token is associated with a cancellation source.
IsCancellationRequested: bool
Whether the associated source has requested cancellation.
Static member:
None: CancellationToken
A token that never requests cancellation.
Methods
5 items
Equals(other: object?) -> bool
Tests reference identity by default; an ordinary class may override equality.
Inherited from Object.Equals
GetHashCode() -> int
Returns a stable identity hash by default; an ordinary class may override it consistently with equality.
Inherited from Object.GetHashCode
GetType() -> TypeInfo
Returns metadata for the concrete runtime type of this instance.
Inherited from Object.GetType
Register(callback: () -> ()) -> CancellationRegistration
Registers an invocation-local callback; an already requested token invokes it inline.
ToString() -> string
Returns the concrete runtime type name for supported references, or display text from a class or boxed-struct override.
Inherited from Object.ToString