Class AmqpJmsMapMessageFacade

java.lang.Object
org.apache.qpid.jms.provider.amqp.message.AmqpJmsMessageFacade
org.apache.qpid.jms.provider.amqp.message.AmqpJmsMapMessageFacade
All Implemented Interfaces:
JmsMapMessageFacade, JmsMessageFacade, TraceableMessage

public class AmqpJmsMapMessageFacade extends AmqpJmsMessageFacade implements JmsMapMessageFacade
Wrapper around an AMQP Message instance that will be treated as a JMS MapMessage type.
  • Constructor Details

    • AmqpJmsMapMessageFacade

      public AmqpJmsMapMessageFacade()
  • Method Details

    • getJmsMsgType

      public byte getJmsMsgType()
      Overrides:
      getJmsMsgType in class AmqpJmsMessageFacade
      Returns:
      the appropriate byte value that indicates the type of message this is.
    • copy

      public AmqpJmsMapMessageFacade copy()
      Description copied from interface: JmsMessageFacade
      Create a new instance and perform a deep copy of this object's contents.
      Specified by:
      copy in interface JmsMapMessageFacade
      Specified by:
      copy in interface JmsMessageFacade
      Overrides:
      copy in class AmqpJmsMessageFacade
      Returns:
      a copy of this JmsMessageFacade instance.
    • getMapNames

      public Enumeration<String> getMapNames()
      Description copied from interface: JmsMapMessageFacade
      Returns an Enumeration of all the names in the MapMessage object.
      Specified by:
      getMapNames in interface JmsMapMessageFacade
      Returns:
      an enumeration of all the names in this MapMessage
    • itemExists

      public boolean itemExists(String key)
      Description copied from interface: JmsMapMessageFacade
      Determines whether an item exists in this Map based message.
      Specified by:
      itemExists in interface JmsMapMessageFacade
      Parameters:
      key - The entry key that is being searched for.
      Returns:
      true if the item exists in the Map, false otherwise.
    • get

      public Object get(String key)
      Description copied from interface: JmsMapMessageFacade
      Gets the value stored in the Map at the specified key.
      Specified by:
      get in interface JmsMapMessageFacade
      Parameters:
      key - the key to use to access a value in the Map.
      Returns:
      the item associated with the given key, or null if not present.
    • put

      public void put(String key, Object value)
      Description copied from interface: JmsMapMessageFacade
      Sets an object value with the specified name into the Map. If a previous mapping for the key exists, the old value is replaced by the specified value. If the value provided is a byte[] its entry then it is assumed that it was copied by the caller and its value will not be altered by the provider.
      Specified by:
      put in interface JmsMapMessageFacade
      Parameters:
      key - the key to use to store the value into the Map.
      value - the new value to store in the element defined by the key.
    • remove

      public Object remove(String key)
      Description copied from interface: JmsMapMessageFacade
      Remove the mapping for this key from the map if present. If the value is not present in the map then this method should return without error or modification to the underlying map.
      Specified by:
      remove in interface JmsMapMessageFacade
      Parameters:
      key - the key to be removed from the map if present.
      Returns:
      the object previously stored in the Map or null if none present.
    • clearBody

      public void clearBody()
      Description copied from interface: JmsMessageFacade
      Clears the contents of this Message.
      Specified by:
      clearBody in interface JmsMessageFacade
      Overrides:
      clearBody in class AmqpJmsMessageFacade
    • hasBody

      public boolean hasBody()
      Description copied from interface: JmsMessageFacade
      Returns true if the underlying message has a body, false if the body is empty.
      Specified by:
      hasBody in interface JmsMessageFacade
      Overrides:
      hasBody in class AmqpJmsMessageFacade
      Returns:
      true if the underlying message has a body, false if the body is empty.
    • asJmsMessage

      public JmsMapMessage asJmsMessage()
      Overrides:
      asJmsMessage in class AmqpJmsMessageFacade
    • initializeEmptyBody

      protected void initializeEmptyBody()
      Description copied from class: AmqpJmsMessageFacade
      Used to indicate that a Message object should empty the body element and make any other internal updates to reflect the message now has no body value.
      Overrides:
      initializeEmptyBody in class AmqpJmsMessageFacade