Adds Generic CommandHandlerDecorator
This commit is contained in:
parent
49f9b99ee1
commit
64e696dc5a
21 changed files with 131 additions and 110 deletions
|
|
@ -1,13 +1,15 @@
|
|||
namespace PlanTempus.Components;
|
||||
using PlanTempus.Core.CommandQueries;
|
||||
|
||||
namespace PlanTempus.Components;
|
||||
|
||||
public interface ICommandHandler
|
||||
{
|
||||
Task<TCommandResult> Handle<TCommand, TCommandResult>(TCommand command);
|
||||
Task<CommandResponse> Handle<TCommand>(TCommand command) where TCommand : ICommand;
|
||||
}
|
||||
|
||||
public interface ICommandHandler<in T, TResult>
|
||||
public interface ICommandHandler<TCommand> where TCommand : ICommand
|
||||
{
|
||||
Task<TResult> Handle(T input);
|
||||
Task<CommandResponse> Handle(TCommand command);
|
||||
}
|
||||
|
||||
public interface ICommandHandlerDecorator
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue