FromCanceled()

System::Threading::Tasks::FromCanceled(const CancellationToken&) function

Creates a task that has completed due to cancellation with the specified token.

TaskPtr System::Threading::Tasks::FromCanceled(const CancellationToken &cancellationToken)

Arguments

ParameterTypeDescription
cancellationTokenconst CancellationToken&The cancellation token that caused the task to be cancelled.

Return Value

A cancelled task.

See Also