public interface QueryMessage<T,R> extends Message<T>
Handlers should only answer a query if they can respond with the appropriate response type.
Modifier and Type | Method and Description |
---|---|
QueryMessage<T,R> |
andMetaData(Map<String,?> additionalMetaData)
Returns a copy of this QueryMessage with its MetaData merged with given
metaData . |
String |
getQueryName()
Returns the name identifying the query to be executed.
|
ResponseType<R> |
getResponseType()
The type of response expected by the sender of the query
|
QueryMessage<T,R> |
withMetaData(Map<String,?> metaData)
Returns a copy of this QueryMessage with the given
metaData . |
getIdentifier, getMetaData, getPayload, getPayloadType
String getQueryName()
ResponseType<R> getResponseType()
QueryMessage<T,R> withMetaData(Map<String,?> metaData)
metaData
. The payload remains unchanged.withMetaData
in interface Message<T>
metaData
- The new MetaData for the QueryMessageQueryMessage<T,R> andMetaData(Map<String,?> additionalMetaData)
metaData
. The payload
remains unchanged.andMetaData
in interface Message<T>
additionalMetaData
- The MetaData to merge into the QueryMessageCopyright © 2010–2018. All rights reserved.