zam_command_pattern library

Classes

AsyncCommand<RESPONSE extends Object?>
A command that responds with a future.
Command<RESPONSE extends Object?>
An object used to encapsulate all information needed to perform an action or trigger an event at a later time.
CommandExecutor<COMMAND extends Command<RESPONSE>, RESPONSE extends Object?>
Contains a list of commands in a factory and executes them on demand.
CommandFactory<COMMAND extends Command<RESPONSE>, RESPONSE extends Object?>
A factory containing a list of commands saved by types as their keys.
ParameterizedAsyncCommand<REQUEST extends Object?, RESPONSE extends Object?>
ParameterizedCommand<REQUEST extends Object?, RESPONSE extends Object?>
ParameterizedReactiveCommand<REQUEST extends Object?, RESPONSE extends Object?>
ReactiveCommand<RESPONSE extends Object?>
A command that responds with a stream.

Typedefs

CommandBuilder<COMMAND extends Command<Object?>> = COMMAND Function()

Exceptions / Errors

CommandNotDefinedException
Exception when command is not found in the factory.