Dispatcher.InvokeAsync Method

Definition

Overloads

InvokeAsync(Action)

Invokes the given Action in the context of the associated Renderer.

InvokeAsync(Func<Task>)

Invokes the given Func<TResult> in the context of the associated Renderer.

InvokeAsync<TResult>(Func<Task<TResult>>)

Invokes the given Func<TResult> in the context of the associated Renderer.

InvokeAsync<TResult>(Func<TResult>)

Invokes the given Func<TResult> in the context of the associated Renderer.

InvokeAsync(Action)

Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs

Invokes the given Action in the context of the associated Renderer.

public:
 abstract System::Threading::Tasks::Task ^ InvokeAsync(Action ^ workItem);
public abstract System.Threading.Tasks.Task InvokeAsync (Action workItem);
abstract member InvokeAsync : Action -> System.Threading.Tasks.Task
Public MustOverride Function InvokeAsync (workItem As Action) As Task

Parameters

workItem
Action

The action to execute.

Returns

A Task that will be completed when the action has finished executing.

Applies to

InvokeAsync(Func<Task>)

Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs

Invokes the given Func<TResult> in the context of the associated Renderer.

public:
 abstract System::Threading::Tasks::Task ^ InvokeAsync(Func<System::Threading::Tasks::Task ^> ^ workItem);
public abstract System.Threading.Tasks.Task InvokeAsync (Func<System.Threading.Tasks.Task> workItem);
abstract member InvokeAsync : Func<System.Threading.Tasks.Task> -> System.Threading.Tasks.Task
Public MustOverride Function InvokeAsync (workItem As Func(Of Task)) As Task

Parameters

workItem
Func<Task>

The asynchronous action to execute.

Returns

A Task that will be completed when the action has finished executing.

Applies to

InvokeAsync<TResult>(Func<Task<TResult>>)

Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs

Invokes the given Func<TResult> in the context of the associated Renderer.

public:
generic <typename TResult>
 abstract System::Threading::Tasks::Task<TResult> ^ InvokeAsync(Func<System::Threading::Tasks::Task<TResult> ^> ^ workItem);
public abstract System.Threading.Tasks.Task<TResult> InvokeAsync<TResult> (Func<System.Threading.Tasks.Task<TResult>> workItem);
abstract member InvokeAsync : Func<System.Threading.Tasks.Task<'Result>> -> System.Threading.Tasks.Task<'Result>
Public MustOverride Function InvokeAsync(Of TResult) (workItem As Func(Of Task(Of TResult))) As Task(Of TResult)

Type Parameters

TResult

Parameters

workItem
Func<Task<TResult>>

The asynchronous function to execute.

Returns

Task<TResult>

A Task<TResult> that will be completed when the function has finished executing.

Applies to

InvokeAsync<TResult>(Func<TResult>)

Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs
Source:
Dispatcher.cs

Invokes the given Func<TResult> in the context of the associated Renderer.

public:
generic <typename TResult>
 abstract System::Threading::Tasks::Task<TResult> ^ InvokeAsync(Func<TResult> ^ workItem);
public abstract System.Threading.Tasks.Task<TResult> InvokeAsync<TResult> (Func<TResult> workItem);
abstract member InvokeAsync : Func<'Result> -> System.Threading.Tasks.Task<'Result>
Public MustOverride Function InvokeAsync(Of TResult) (workItem As Func(Of TResult)) As Task(Of TResult)

Type Parameters

TResult

Parameters

workItem
Func<TResult>

The function to execute.

Returns

Task<TResult>

A Task<TResult> that will be completed when the function has finished executing.

Applies to