Skip to content

M_CodeJam_Threading_AsyncOperationHelper_Send__1

Andrew Koryavchenko edited this page Jun 17, 2018 · 7 revisions

AsyncOperationHelper.Send(T) Method (AsyncOperation, Func(T))

Invokes a runner on the thread or context appropriate for the application model and returns result.

Namespace: CodeJam.Threading
Assembly: CodeJam (in CodeJam.dll) Version: 2.1.0.0

Syntax

C#

public static T Send<T>(
	this AsyncOperation asyncOp,
	Func<T> runner
)

VB

<ExtensionAttribute>
Public Shared Function Send(Of T) ( 
	asyncOp As AsyncOperation,
	runner As Func(Of T)
) As T

F#

[<ExtensionAttribute>]
static member Send : 
        asyncOp : AsyncOperation * 
        runner : Func<'T> -> 'T 

Parameters

 

asyncOp
Type: System.ComponentModel.AsyncOperation
runner
Type: System.Func(T)
A Func(TResult) that wraps the delegate to be called when the operation ends.

Type Parameters

 

T
[Missing documentation for "M:CodeJam.Threading.AsyncOperationHelper.Send1(System.ComponentModel.AsyncOperation,System.Func{0})"]

Return Value

Type: T
Result of runner execution.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type AsyncOperation. 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

Reference

AsyncOperationHelper Class
Send Overload
CodeJam.Threading Namespace

Clone this wiki locally