Class TaskActionFactory<TTuple>
Provides an easy way of invoking an System.Action delegate regardless of the amount of parameters provided.
Inherited Members
Namespace: Cuemon
Assembly: Cuemon.Core.dll
Syntax
public sealed class TaskActionFactory<TTuple> : TemplateFactory<TTuple> where TTuple : Template
Type Parameters
Name | Description |
---|---|
TTuple | The type of the n-tuple representation of a Template. |
Constructors
| Improve this DocTaskActionFactory(Func<TTuple, Task>, TTuple)
Initializes a new instance of the TaskActionFactory class.
Declaration
public TaskActionFactory(Func<TTuple, Task> method, TTuple tuple)
Parameters
Type | Name | Description |
---|---|---|
System.Func<TTuple, System.Threading.Tasks.Task> | method | The System.Threading.Tasks.Task based function delegate to invoke. |
TTuple | tuple | The n-tuple argument of |
Methods
| Improve this DocClone()
Creates a shallow copy of the current TaskActionFactory<TTuple> object.
Declaration
public TaskActionFactory<TTuple> Clone()
Returns
Type | Description |
---|---|
TaskActionFactory<TTuple> | A new TaskActionFactory<TTuple> that is a copy of this instance. |
Remarks
When thread safety is required this is the method to invoke.
ExecuteMethodAsync()
Executes the delegate associated with this instance.
Declaration
public Task ExecuteMethodAsync()
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task |