Compartir a través de


FuncTaskActivity.Create<TInput,TOutput> Method

Definition

Creates a new TaskActivity<TInput,TOutput> with the provided function as the implementation.

public static Microsoft.DurableTask.TaskActivity<TInput,TOutput> Create<TInput,TOutput> (Func<Microsoft.DurableTask.TaskActivityContext,TInput,System.Threading.Tasks.Task<TOutput>> implementation);
static member Create : Func<Microsoft.DurableTask.TaskActivityContext, 'Input, System.Threading.Tasks.Task<'Output>> -> Microsoft.DurableTask.TaskActivity<'Input, 'Output>
Public Shared Function Create(Of TInput, TOutput) (implementation As Func(Of TaskActivityContext, TInput, Task(Of TOutput))) As TaskActivity(Of TInput, TOutput)

Type Parameters

TInput

The input type.

TOutput

The output type.

Parameters

implementation
Func<TaskActivityContext,TInput,Task<TOutput>>

The activity implementation.

Returns

A new activity.

Applies to