Command refactor
This commit is contained in:
@@ -1,9 +0,0 @@
|
||||
using FileTime.App.Core.Command;
|
||||
|
||||
namespace FileTime.App.Core.Services;
|
||||
|
||||
public interface ICommandHandler
|
||||
{
|
||||
bool CanHandleCommand(Command.Command command);
|
||||
Task HandleCommandAsync(Command.Command command);
|
||||
}
|
||||
@@ -1,8 +0,0 @@
|
||||
using FileTime.App.Core.Command;
|
||||
|
||||
namespace FileTime.App.Core.Services;
|
||||
|
||||
public interface ICommandHandlerService
|
||||
{
|
||||
Task HandleCommandAsync(Command.Command command);
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using FileTime.App.Core.UserCommand;
|
||||
|
||||
namespace FileTime.App.Core.Services;
|
||||
|
||||
public interface IIdentifiableUserCommandService
|
||||
{
|
||||
void AddIdentifiableUserCommandFactory(string identifier, Func<IIdentifiableUserCommand> commandFactory);
|
||||
IIdentifiableUserCommand GetCommand(string identifier);
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using FileTime.App.Core.UserCommand;
|
||||
|
||||
namespace FileTime.App.Core.Services;
|
||||
|
||||
public interface IUserCommandHandler
|
||||
{
|
||||
bool CanHandleCommand(IUserCommand command);
|
||||
Task HandleCommandAsync(IUserCommand command);
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace FileTime.App.Core.Services;
|
||||
|
||||
public interface IUserCommandHandlerService
|
||||
{
|
||||
Task HandleCommandAsync(UserCommand.IUserCommand command);
|
||||
Task HandleCommandAsync<TCommand>() where TCommand : UserCommand.IUserCommand, new();
|
||||
}
|
||||
Reference in New Issue
Block a user