public class JsonInboundMessageMapper extends AbstractJsonInboundMessageMapper<JsonInboundMessageMapper.JsonMessageParser<?>>
InboundMessageMapper
implementation that maps incoming JSON messages
to a Message
with the specified payload type.Modifier and Type | Class and Description |
---|---|
static interface |
JsonInboundMessageMapper.JsonMessageParser<P> |
DEFAULT_HEADER_TYPES, headerTypes, mapToPayload, MESSAGE_FORMAT_ERROR, payloadType
Constructor and Description |
---|
JsonInboundMessageMapper(java.lang.Class<?> payloadType,
JsonInboundMessageMapper.JsonMessageParser<?> messageParser) |
JsonInboundMessageMapper(java.lang.reflect.Type payloadType,
JsonInboundMessageMapper.JsonMessageParser<?> messageParser) |
Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.String,java.lang.Class<?>> |
getHeaderTypes() |
java.lang.reflect.Type |
getPayloadType() |
boolean |
isMapToPayload() |
protected java.util.Map<java.lang.String,java.lang.Object> |
readHeaders(JsonInboundMessageMapper.JsonMessageParser<?> parser,
java.lang.String jsonMessage) |
protected java.lang.Object |
readPayload(JsonInboundMessageMapper.JsonMessageParser<?> parser,
java.lang.String jsonMessage) |
Message<?> |
toMessage(java.lang.String jsonMessage) |
setHeaderTypes, setMapToPayload
public JsonInboundMessageMapper(java.lang.Class<?> payloadType, JsonInboundMessageMapper.JsonMessageParser<?> messageParser)
public JsonInboundMessageMapper(java.lang.reflect.Type payloadType, JsonInboundMessageMapper.JsonMessageParser<?> messageParser)
public boolean isMapToPayload()
public java.lang.reflect.Type getPayloadType()
public java.util.Map<java.lang.String,java.lang.Class<?>> getHeaderTypes()
public Message<?> toMessage(java.lang.String jsonMessage) throws java.lang.Exception
java.lang.Exception
protected java.util.Map<java.lang.String,java.lang.Object> readHeaders(JsonInboundMessageMapper.JsonMessageParser<?> parser, java.lang.String jsonMessage) throws java.lang.Exception
readHeaders
in class AbstractJsonInboundMessageMapper<JsonInboundMessageMapper.JsonMessageParser<?>>
java.lang.Exception
protected java.lang.Object readPayload(JsonInboundMessageMapper.JsonMessageParser<?> parser, java.lang.String jsonMessage) throws java.lang.Exception
readPayload
in class AbstractJsonInboundMessageMapper<JsonInboundMessageMapper.JsonMessageParser<?>>
java.lang.Exception