Interface ICommandResponseValueHandler
- Namespace
- Cratis.Applications.Commands
- Assembly
- Cratis.Applications.dll
Defines a handler for processing command response values.
public interface ICommandResponseValueHandler
Methods
CanHandle(CommandContext, object)
Determines whether this handler can handle the given value.
bool CanHandle(CommandContext commandContext, object value)
Parameters
commandContext
CommandContextContext for the command resulting in the value.
value
objectValue to evaluate.
Returns
- bool
True if the handler can handle the value, false otherwise.
Handle(CommandContext, object)
Handles the given value.
Task<CommandResult> Handle(CommandContext commandContext, object value)
Parameters
commandContext
CommandContextContext for the command resulting in the value.
value
objectValue to handle.
Returns
- Task<CommandResult>
CommandResult representing the result of handling the value.