Class AbstractJsonInboundMessageMapper<P>

java.lang.Object
org.springframework.integration.support.json.AbstractJsonInboundMessageMapper<P>
Type Parameters:
P - the payload type.
All Implemented Interfaces:
InboundMessageMapper<String>
Direct Known Subclasses:
JsonInboundMessageMapper

public abstract class AbstractJsonInboundMessageMapper<P> extends Object implements InboundMessageMapper<String>
Abstract InboundMessageMapper implementation that maps incoming JSON messages to a Message with the specified payload type.
Since:
3.0
Author:
Artem Bilan, Gary Russell, Ngoc Nhan
See Also:
  • Field Details

    • MESSAGE_FORMAT_ERROR

      protected static final String MESSAGE_FORMAT_ERROR
      See Also:
    • DEFAULT_HEADER_TYPES

      protected static final Map<String,Class<?>> DEFAULT_HEADER_TYPES
    • payloadType

      protected final Type payloadType
    • headerTypes

      protected final Map<String,Class<?>> headerTypes
  • Constructor Details

    • AbstractJsonInboundMessageMapper

      public AbstractJsonInboundMessageMapper(Type payloadType)
  • Method Details

    • setHeaderTypes

      public void setHeaderTypes(Map<String,Class<?>> headerTypes)
    • setMapToPayload

      public void setMapToPayload(boolean mapToPayload)
    • isMapToPayload

      public boolean isMapToPayload()
    • readPayload

      protected abstract Object readPayload(P parser, String jsonMessage)
    • readHeaders

      protected abstract Map<String,Object> readHeaders(P parser, String jsonMessage)