AbstractCommandHandlingClass

public abstract class AbstractCommandHandlingClass<C, R extends MessageClass<?>, H extends CommandAcceptingMethod<? extends Object, R>> extends ModelClass<T> implements CommandHandlingClass<R, H>

Abstract base for classes providing message handling information of classes that handle commands.

Parameters

<C>

the type of a command handling class

<R>

the type of the class of produced messages

<H>

the type of methods performing the command handle

Inheritors

Functions

Link copied to clipboard
public ImmutableSet<R> commandOutput()
Obtains classes of all messages produced as a result of command handling.
Link copied to clipboard
public ImmutableSet<CommandClass> commands()
Obtains classes of commands handled by the class.
Link copied to clipboard
public H handlerOf(CommandClass commandClass)
Obtains the handler method for the passed command class.
Link copied to clipboard
public ImmutableSet<EventClass> rejections()
Obtains classes of rejections that command handling methods of this class throw, or empty set if no rejections are thrown.

Inherited functions

Link copied to clipboard
protected static ModelClass<T> get<T, M extends ModelClass<T>>(Class<T> rawClass, Class<M> requestedModelClass, Supplier<ModelClass<T>> supplier)
Obtains the model class for the passed raw class.