T
- The type of payload contained in the messagepublic interface CommandMessage<T> extends Message<T>
Modifier and Type | Method and Description |
---|---|
CommandMessage<T> |
andMetaData(Map<String,?> metaData)
Returns a copy of this CommandMessage with it MetaData merged with the given
metaData . |
String |
getCommandName()
Returns the name of the command to execute.
|
CommandMessage<T> |
withMetaData(Map<String,?> metaData)
Returns a copy of this CommandMessage with the given
metaData . |
getIdentifier, getMetaData, getPayload, getPayloadType, serializeMetaData, serializePayload
String getCommandName()
CommandMessage<T> withMetaData(@Nonnull Map<String,?> metaData)
metaData
. The payload remains unchanged.
While the implementation returned may be different than the implementation of this
, implementations
must take special care in returning the same type of Message (e.g. EventMessage, DomainEventMessage) to prevent
errors further downstream.withMetaData
in interface Message<T>
metaData
- The new MetaData for the MessageCommandMessage<T> andMetaData(@Nonnull Map<String,?> metaData)
metaData
. The payload
remains unchanged.andMetaData
in interface Message<T>
metaData
- The MetaData to merge withCopyright © 2010–2023. All rights reserved.