Click or drag to resize
PromisesToTaskT Method
Convert a promise to a .Net 4.0 Task for use with the async/await keywords

Namespace: Innovator.Client
Assembly: Innovator.Client (in Innovator.Client.dll) Version: 2016.1.15.1759 (2016.01.15.1759)
Syntax
public static Task<T> ToTask<T>(
	this IPromise<T> promise,
	CancellationToken ct = null
)

Parameters

promise
Type: Innovator.ClientIPromiseT
ct (Optional)
Type: System.ThreadingCancellationToken

Type Parameters

T

Return Value

Type: TaskT

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type IPromiseT. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also