create
Creates a new Command with the given message.
Return
new command instance
Parameters
message
the command message
Throws
Validation Exception
if the passed message does not satisfy the constraints, set for it in its Protobuf definition
Creates a new Command
with the passed message and target entity version.
The targetVersion
parameter defines the version of the entity which handles the resulting command. Note that the framework performs no validation of the target version before a command is handled. Instead users themselves can perform validation.
Return
new command instance
Parameters
message
the command message
target Version
the version of the entity for which this command is intended
Throws
Validation Exception
if the passed message does not satisfy the constraints set for it in its Protobuf definition