org.jboss.messaging.ra
Class JBMMapMessage

java.lang.Object
  extended by org.jboss.messaging.ra.JBMMessage
      extended by org.jboss.messaging.ra.JBMMapMessage
All Implemented Interfaces:
javax.jms.MapMessage, javax.jms.Message

public class JBMMapMessage
extends JBMMessage
implements javax.jms.MapMessage

A wrapper for a message

Version:
$Revision: 71554 $
Author:
Adrian Brock, Jesper Pedersen

Field Summary
 
Fields inherited from class org.jboss.messaging.ra.JBMMessage
message, session
 
Fields inherited from interface javax.jms.Message
DEFAULT_DELIVERY_MODE, DEFAULT_PRIORITY, DEFAULT_TIME_TO_LIVE
 
Constructor Summary
JBMMapMessage(javax.jms.MapMessage message, JBMSession session)
          Create a new wrapper
 
Method Summary
 boolean getBoolean(java.lang.String name)
          Get
 byte getByte(java.lang.String name)
          Get
 byte[] getBytes(java.lang.String name)
          Get
 char getChar(java.lang.String name)
          Get
 double getDouble(java.lang.String name)
          Get
 float getFloat(java.lang.String name)
          Get
 int getInt(java.lang.String name)
          Get
 long getLong(java.lang.String name)
          Get
 java.util.Enumeration getMapNames()
          Get the map names
 java.lang.Object getObject(java.lang.String name)
          Get
 short getShort(java.lang.String name)
          Get
 java.lang.String getString(java.lang.String name)
          Get
 boolean itemExists(java.lang.String name)
          Does the item exist
 void setBoolean(java.lang.String name, boolean value)
          Set
 void setByte(java.lang.String name, byte value)
          Set
 void setBytes(java.lang.String name, byte[] value)
          Set
 void setBytes(java.lang.String name, byte[] value, int offset, int length)
          Set
 void setChar(java.lang.String name, char value)
          Set
 void setDouble(java.lang.String name, double value)
          Set
 void setFloat(java.lang.String name, float value)
          Set
 void setInt(java.lang.String name, int value)
          Set
 void setLong(java.lang.String name, long value)
          Set
 void setObject(java.lang.String name, java.lang.Object value)
          Set
 void setShort(java.lang.String name, short value)
          Set
 void setString(java.lang.String name, java.lang.String value)
          Set
 
Methods inherited from class org.jboss.messaging.ra.JBMMessage
acknowledge, clearBody, clearProperties, equals, getBooleanProperty, getByteProperty, getDoubleProperty, getFloatProperty, getIntProperty, getJMSCorrelationID, getJMSCorrelationIDAsBytes, getJMSDeliveryMode, getJMSDestination, getJMSExpiration, getJMSMessageID, getJMSPriority, getJMSRedelivered, getJMSReplyTo, getJMSTimestamp, getJMSType, getLongProperty, getObjectProperty, getPropertyNames, getShortProperty, getStringProperty, hashCode, propertyExists, setBooleanProperty, setByteProperty, setDoubleProperty, setFloatProperty, setIntProperty, setJMSCorrelationID, setJMSCorrelationIDAsBytes, setJMSDeliveryMode, setJMSDestination, setJMSExpiration, setJMSMessageID, setJMSPriority, setJMSRedelivered, setJMSReplyTo, setJMSTimestamp, setJMSType, setLongProperty, setObjectProperty, setShortProperty, setStringProperty, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface javax.jms.Message
acknowledge, clearBody, clearProperties, getBooleanProperty, getByteProperty, getDoubleProperty, getFloatProperty, getIntProperty, getJMSCorrelationID, getJMSCorrelationIDAsBytes, getJMSDeliveryMode, getJMSDestination, getJMSExpiration, getJMSMessageID, getJMSPriority, getJMSRedelivered, getJMSReplyTo, getJMSTimestamp, getJMSType, getLongProperty, getObjectProperty, getPropertyNames, getShortProperty, getStringProperty, propertyExists, setBooleanProperty, setByteProperty, setDoubleProperty, setFloatProperty, setIntProperty, setJMSCorrelationID, setJMSCorrelationIDAsBytes, setJMSDeliveryMode, setJMSDestination, setJMSExpiration, setJMSMessageID, setJMSPriority, setJMSRedelivered, setJMSReplyTo, setJMSTimestamp, setJMSType, setLongProperty, setObjectProperty, setShortProperty, setStringProperty
 

Constructor Detail

JBMMapMessage

public JBMMapMessage(javax.jms.MapMessage message,
                     JBMSession session)
Create a new wrapper

Parameters:
message - the message
session - the session
Method Detail

getBoolean

public boolean getBoolean(java.lang.String name)
                   throws javax.jms.JMSException
Get

Specified by:
getBoolean in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getByte

public byte getByte(java.lang.String name)
             throws javax.jms.JMSException
Get

Specified by:
getByte in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getBytes

public byte[] getBytes(java.lang.String name)
                throws javax.jms.JMSException
Get

Specified by:
getBytes in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getChar

public char getChar(java.lang.String name)
             throws javax.jms.JMSException
Get

Specified by:
getChar in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getDouble

public double getDouble(java.lang.String name)
                 throws javax.jms.JMSException
Get

Specified by:
getDouble in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getFloat

public float getFloat(java.lang.String name)
               throws javax.jms.JMSException
Get

Specified by:
getFloat in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getInt

public int getInt(java.lang.String name)
           throws javax.jms.JMSException
Get

Specified by:
getInt in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getLong

public long getLong(java.lang.String name)
             throws javax.jms.JMSException
Get

Specified by:
getLong in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getMapNames

public java.util.Enumeration getMapNames()
                                  throws javax.jms.JMSException
Get the map names

Specified by:
getMapNames in interface javax.jms.MapMessage
Returns:
The values
Throws:
javax.jms.JMSException - Thrown if an error occurs

getObject

public java.lang.Object getObject(java.lang.String name)
                           throws javax.jms.JMSException
Get

Specified by:
getObject in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getShort

public short getShort(java.lang.String name)
               throws javax.jms.JMSException
Get

Specified by:
getShort in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

getString

public java.lang.String getString(java.lang.String name)
                           throws javax.jms.JMSException
Get

Specified by:
getString in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

itemExists

public boolean itemExists(java.lang.String name)
                   throws javax.jms.JMSException
Does the item exist

Specified by:
itemExists in interface javax.jms.MapMessage
Parameters:
name - The name
Returns:
True / false
Throws:
javax.jms.JMSException - Thrown if an error occurs

setBoolean

public void setBoolean(java.lang.String name,
                       boolean value)
                throws javax.jms.JMSException
Set

Specified by:
setBoolean in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setByte

public void setByte(java.lang.String name,
                    byte value)
             throws javax.jms.JMSException
Set

Specified by:
setByte in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setBytes

public void setBytes(java.lang.String name,
                     byte[] value,
                     int offset,
                     int length)
              throws javax.jms.JMSException
Set

Specified by:
setBytes in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
offset - The offset
length - The length
Throws:
javax.jms.JMSException - Thrown if an error occurs

setBytes

public void setBytes(java.lang.String name,
                     byte[] value)
              throws javax.jms.JMSException
Set

Specified by:
setBytes in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setChar

public void setChar(java.lang.String name,
                    char value)
             throws javax.jms.JMSException
Set

Specified by:
setChar in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setDouble

public void setDouble(java.lang.String name,
                      double value)
               throws javax.jms.JMSException
Set

Specified by:
setDouble in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setFloat

public void setFloat(java.lang.String name,
                     float value)
              throws javax.jms.JMSException
Set

Specified by:
setFloat in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setInt

public void setInt(java.lang.String name,
                   int value)
            throws javax.jms.JMSException
Set

Specified by:
setInt in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setLong

public void setLong(java.lang.String name,
                    long value)
             throws javax.jms.JMSException
Set

Specified by:
setLong in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setObject

public void setObject(java.lang.String name,
                      java.lang.Object value)
               throws javax.jms.JMSException
Set

Specified by:
setObject in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setShort

public void setShort(java.lang.String name,
                     short value)
              throws javax.jms.JMSException
Set

Specified by:
setShort in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs

setString

public void setString(java.lang.String name,
                      java.lang.String value)
               throws javax.jms.JMSException
Set

Specified by:
setString in interface javax.jms.MapMessage
Parameters:
name - The name
value - The value
Throws:
javax.jms.JMSException - Thrown if an error occurs


Copyright © 2006 JBoss Inc. All Rights Reserved.