Edit

Share via


BatchWorkerFromDelegate Constructors

Definition

Overloads

BatchWorkerFromDelegate(Func<Task>)
BatchWorkerFromDelegate(Func<Task>, CancellationToken)

Initializes a new BatchWorkerFromDelegate instance.

BatchWorkerFromDelegate(Func<Task>)

public BatchWorkerFromDelegate (Func<System.Threading.Tasks.Task> work);
new Orleans.BatchWorkerFromDelegate : Func<System.Threading.Tasks.Task> -> Orleans.BatchWorkerFromDelegate
Public Sub New (work As Func(Of Task))

Parameters

work
Func<Task>

Applies to

BatchWorkerFromDelegate(Func<Task>, CancellationToken)

Source:
BatchWorker.cs

Initializes a new BatchWorkerFromDelegate instance.

public BatchWorkerFromDelegate (Func<System.Threading.Tasks.Task> work, System.Threading.CancellationToken cancellationToken = default);
new Orleans.BatchWorkerFromDelegate : Func<System.Threading.Tasks.Task> * System.Threading.CancellationToken -> Orleans.BatchWorkerFromDelegate
Public Sub New (work As Func(Of Task), Optional cancellationToken As CancellationToken = Nothing)

Parameters

work
Func<Task>

The delegate to invoke when Work() is invoked.

cancellationToken
CancellationToken

The cancellation token used to stop the worker.

Applies to