public class RMQMapMessage extends RMQMessage implements javax.jms.MapMessage
MapMessage interface.DEFAULT_MESSAGE_BODY_SIZE, logger, MSG_EOF, NOT_READABLE, NOT_WRITEABLE, UNABLE_TO_CAST| Constructor and Description |
|---|
RMQMapMessage() |
| Modifier and Type | Method and Description |
|---|---|
void |
clearBodyInternal() |
protected <T> T |
doGetBody(java.lang.Class<T> c) |
boolean |
getBoolean(java.lang.String name) |
byte |
getByte(java.lang.String name) |
byte[] |
getBytes(java.lang.String name) |
char |
getChar(java.lang.String name) |
double |
getDouble(java.lang.String name) |
float |
getFloat(java.lang.String name) |
int |
getInt(java.lang.String name) |
long |
getLong(java.lang.String name) |
java.util.Enumeration<java.lang.String> |
getMapNames() |
java.lang.Object |
getObject(java.lang.String name) |
short |
getShort(java.lang.String name) |
java.lang.String |
getString(java.lang.String name) |
boolean |
isBodyAssignableTo(java.lang.Class c) |
boolean |
itemExists(java.lang.String name) |
protected void |
readAmqpBody(byte[] barr)
Invoked when an AMQP message is being transformed into a RMQMessage
The implementing class should only read its body by this method
|
protected void |
readBody(java.io.ObjectInput inputStream,
java.io.ByteArrayInputStream bin)
Invoked when a message is being deserialized to read and decode the message body.
|
static RMQMessage |
recreate(javax.jms.MapMessage msg) |
void |
setBoolean(java.lang.String name,
boolean value) |
void |
setByte(java.lang.String name,
byte value) |
void |
setBytes(java.lang.String name,
byte[] value) |
void |
setBytes(java.lang.String name,
byte[] value,
int offset,
int length) |
void |
setChar(java.lang.String name,
char value) |
void |
setDouble(java.lang.String name,
double value) |
void |
setFloat(java.lang.String name,
float value) |
void |
setInt(java.lang.String name,
int value) |
void |
setLong(java.lang.String name,
long value) |
void |
setObject(java.lang.String name,
java.lang.Object value) |
void |
setShort(java.lang.String name,
short value) |
void |
setString(java.lang.String name,
java.lang.String value) |
protected void |
writeAmqpBody(java.io.ByteArrayOutputStream out)
Invoked when
RMQMessage.toAmqpByteArray() is called to create
a byte[] from a message. |
protected void |
writeBody(java.io.ObjectOutput out,
java.io.ByteArrayOutputStream bout)
Invoked when
RMQMessage.toByteArray() is called to create
a byte[] from a message. |
acknowledge, clearBody, clearProperties, clone, copyAttributes, doNotDeclareReplyToDestination, equals, getBody, getBooleanProperty, getByteProperty, getDoubleProperty, getFloatProperty, getInternalID, getIntProperty, getJMSCorrelationID, getJMSCorrelationIDAsBytes, getJMSDeliveryMode, getJMSDeliveryTime, getJMSDestination, getJMSExpiration, getJMSMessageID, getJMSPriority, getJMSRedelivered, getJMSReplyTo, getJMSTimestamp, getJMSType, getLongProperty, getObjectProperty, getPropertyNames, getRabbitDeliveryTag, getSession, getShortProperty, getStringProperty, hashCode, isReadonlyBody, isReadOnlyProperties, loggerDebugByteArray, propertyExists, readPrimitive, setBooleanProperty, setByteProperty, setDoubleProperty, setFloatProperty, setIntProperty, setJMSCorrelationID, setJMSCorrelationIDAsBytes, setJMSDeliveryMode, setJMSDeliveryTime, setJMSDestination, setJMSExpiration, setJMSMessageID, setJMSPriority, setJMSRedelivered, setJMSReplyTo, setJMSTimestamp, setJMSType, setLongProperty, setObjectProperty, setRabbitDeliveryTag, setReadonly, setReadOnlyBody, setReadOnlyProperties, setSession, setShortProperty, setStringProperty, writePrimitive, writePrimitivefinalize, getClass, notify, notifyAll, toString, wait, wait, waitacknowledge, clearBody, clearProperties, getBody, getBooleanProperty, getByteProperty, getDoubleProperty, getFloatProperty, getIntProperty, getJMSCorrelationID, getJMSCorrelationIDAsBytes, getJMSDeliveryMode, getJMSDeliveryTime, getJMSDestination, getJMSExpiration, getJMSMessageID, getJMSPriority, getJMSRedelivered, getJMSReplyTo, getJMSTimestamp, getJMSType, getLongProperty, getObjectProperty, getPropertyNames, getShortProperty, getStringProperty, propertyExists, setBooleanProperty, setByteProperty, setDoubleProperty, setFloatProperty, setIntProperty, setJMSCorrelationID, setJMSCorrelationIDAsBytes, setJMSDeliveryMode, setJMSDeliveryTime, setJMSDestination, setJMSExpiration, setJMSMessageID, setJMSPriority, setJMSRedelivered, setJMSReplyTo, setJMSTimestamp, setJMSType, setLongProperty, setObjectProperty, setShortProperty, setStringPropertypublic boolean getBoolean(java.lang.String name)
throws javax.jms.JMSException
getBoolean in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic byte getByte(java.lang.String name)
throws javax.jms.JMSException
getByte in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic short getShort(java.lang.String name)
throws javax.jms.JMSException
getShort in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic char getChar(java.lang.String name)
throws javax.jms.JMSException
getChar in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic int getInt(java.lang.String name)
throws javax.jms.JMSException
getInt in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic long getLong(java.lang.String name)
throws javax.jms.JMSException
getLong in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic float getFloat(java.lang.String name)
throws javax.jms.JMSException
getFloat in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic double getDouble(java.lang.String name)
throws javax.jms.JMSException
getDouble in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic java.lang.String getString(java.lang.String name)
throws javax.jms.JMSException
getString in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic byte[] getBytes(java.lang.String name)
throws javax.jms.JMSException
getBytes in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic java.lang.Object getObject(java.lang.String name)
throws javax.jms.JMSException
getObject in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic java.util.Enumeration<java.lang.String> getMapNames()
throws javax.jms.JMSException
getMapNames in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setBoolean(java.lang.String name,
boolean value)
throws javax.jms.JMSException
setBoolean in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setByte(java.lang.String name,
byte value)
throws javax.jms.JMSException
setByte in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setShort(java.lang.String name,
short value)
throws javax.jms.JMSException
setShort in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setChar(java.lang.String name,
char value)
throws javax.jms.JMSException
setChar in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setInt(java.lang.String name,
int value)
throws javax.jms.JMSException
setInt in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setLong(java.lang.String name,
long value)
throws javax.jms.JMSException
setLong in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setFloat(java.lang.String name,
float value)
throws javax.jms.JMSException
setFloat in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setDouble(java.lang.String name,
double value)
throws javax.jms.JMSException
setDouble in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setString(java.lang.String name,
java.lang.String value)
throws javax.jms.JMSException
setString in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setBytes(java.lang.String name,
byte[] value)
throws javax.jms.JMSException
setBytes in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setBytes(java.lang.String name,
byte[] value,
int offset,
int length)
throws javax.jms.JMSException
setBytes in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void setObject(java.lang.String name,
java.lang.Object value)
throws javax.jms.JMSException
setObject in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic boolean itemExists(java.lang.String name)
throws javax.jms.JMSException
itemExists in interface javax.jms.MapMessagejavax.jms.JMSExceptionpublic void clearBodyInternal()
throws javax.jms.JMSException
clearBodyInternal in class RMQMessagejavax.jms.JMSExceptionprotected void writeBody(java.io.ObjectOutput out,
java.io.ByteArrayOutputStream bout)
throws java.io.IOException
RMQMessageRMQMessage.toByteArray() is called to create
a byte[] from a message. Each subclass must implement this, but ONLY
write its specific body. All the properties defined in Message
will be written by the parent class.writeBody in class RMQMessageout - - the output stream to which the structured part of message body (scalar types) is writtenbout - - the output stream to which the un-structured part of message body (explicit bytes) is writtenjava.io.IOException - if the body can not be writtenprotected void readBody(java.io.ObjectInput inputStream,
java.io.ByteArrayInputStream bin)
throws java.io.IOException,
java.lang.ClassNotFoundException
RMQMessagereadBody in class RMQMessageinputStream - - the stream to read its body frombin - - the underlying byte input streamjava.io.IOException - if a read error occurs on the input streamjava.lang.ClassNotFoundException - if the object class cannot be foundprotected void readAmqpBody(byte[] barr)
RMQMessagereadAmqpBody in class RMQMessagebarr - - the byte array payload of the AMQP messageprotected void writeAmqpBody(java.io.ByteArrayOutputStream out)
throws java.io.IOException
RMQMessageRMQMessage.toAmqpByteArray() is called to create
a byte[] from a message. Each subclass must implement this, but ONLY
write its specific body.writeAmqpBody in class RMQMessageout - - the output stream to which the message body is writtenjava.io.IOException - if the body can not be writtenpublic static RMQMessage recreate(javax.jms.MapMessage msg) throws javax.jms.JMSException
javax.jms.JMSExceptionpublic boolean isBodyAssignableTo(java.lang.Class c)
isBodyAssignableTo in interface javax.jms.Messageprotected <T> T doGetBody(java.lang.Class<T> c)
doGetBody in class RMQMessageCopyright © 2022. All rights reserved.