Windows Dev Center

TaskFactory<TResult>.CancellationToken Property

Gets the default cancellation token for this task factory.

Namespace:  System.Threading.Tasks
Assembly:  mscorlib (in mscorlib.dll)

public CancellationToken CancellationToken { get; }

Property Value

Type: System.Threading.CancellationToken
The default cancellation token for this task factory.

This property returns the default cancellation token that will be assigned to all tasks created by this factory unless another cancellation token value is explicitly specified during the call to the task factory methods.

Windows Phone OS

Supported in: 8.1, 8.0

Show:
© 2015 Microsoft