Class CommandHandler<TCommand, TResult>
inherit this base class if you'd like to manipulate validation state of the calling endpoint from within the command handler.
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: FastEndpoints
Assembly: FastEndpoints.dll
Syntax
public abstract class CommandHandler<TCommand, TResult> : CommandHandlerBase<TCommand>, ICommandHandler<TCommand, TResult>, ICommandHandler where TCommand : ICommand<TResult>
Type Parameters
Name | Description |
---|---|
TCommand | the type of the command that will be handled by this command handler |
TResult | the type of the result that will be returned by this command handler |
Methods
ExecuteAsync(TCommand, CancellationToken)
inherit this base class if you'd like to manipulate validation state of the calling endpoint from within the command handler.
Declaration
public abstract Task<TResult> ExecuteAsync(TCommand command, CancellationToken ct = default(CancellationToken))
Parameters
Type | Name | Description |
---|---|---|
TCommand | command | |
System.Threading.CancellationToken | ct |
Returns
Type | Description |
---|---|
System.Threading.Tasks.Task<TResult> |