C-DEngine 5.105

TheCommonUtils..::..TaskWaitCancel Method

Returns a task that completes when the task completes or the cancelToken was canceled. Note that the underlying task will NOT be canceled, only the await/Wait for the returned task will be canceled.

Namespace:  nsCDEngine.BaseClasses
Assembly:  C-DEngine (in C-DEngine.dll)

Syntax


public static Task TaskWaitCancel(
	Task task,
	CancellationToken cancelToken
)
Public Shared Function TaskWaitCancel ( _
	task As Task, _
	cancelToken As CancellationToken _
) As Task
public:
static Task^ TaskWaitCancel(
	Task^ task, 
	CancellationToken^ cancelToken
)

Parameters

task
Type: Task
Task to waited for.
cancelToken
Type: CancellationToken
CancellationToken to be observed while waiting for the task.

Return Value

The completed task.