org.jboss.mq
Class SpyObjectMessage
java.lang.Object
org.jboss.mq.SpyMessage (src)
org.jboss.mq.SpyObjectMessage
- All Implemented Interfaces:
- java.lang.Cloneable, java.lang.Comparable, java.io.Externalizable, Message (src) , ObjectMessage (src) , java.io.Serializable
- Direct Known Subclasses:
- SpyEncapsulatedMessage (src)
- public class SpyObjectMessage
- extends SpyMessage (src)
- implements ObjectMessage (src) , java.io.Externalizable
This class implements javax.jms.ObjectMessage
- See Also:
- Serialized Form
Fields inherited from class org.jboss.mq.SpyMessage (src) |
ack, BOOLEAN, BYTE, BYTES_MESS, DOUBLE, ENCAP_MESS, FLOAT, header, INT, LONG, MAP_MESS, NULL, OBJECT, OBJECT_MESS, PROPERTY_REDELIVERY_COUNT, PROPERTY_REDELIVERY_DELAY, PROPERTY_REDELIVERY_LIMIT, PROPERTY_SCHEDULED_DELIVERY, session, SHORT, SPY_MESS, STREAM_MESS, STRING, TEXT_MESS |
Method Summary |
void |
clearBody()
Clears out the message body. |
java.io.Serializable |
getObject()
Gets the serializable object containing this message's data. |
SpyMessage (src) |
myClone()
Clone the message |
void |
readExternal(java.io.ObjectInput in)
|
void |
setObject(java.io.Serializable object)
Sets the serializable object containing this message's data. |
void |
writeExternal(java.io.ObjectOutput out)
|
Methods inherited from class org.jboss.mq.SpyMessage (src) |
acknowledge, clearProperties, compareTo, copyProps, createAcknowledgementRequest, doAcknowledge, doNegAcknowledge, getAcknowledgementRequest, getBooleanProperty, getByteProperty, getDoubleProperty, getFloatProperty, getIntProperty, getJMSCorrelationID, getJMSCorrelationIDAsBytes, getJMSDeliveryMode, getJMSDestination, getJMSExpiration, getJMSMessageID, getJMSPriority, getJMSRedelivered, getJMSReplyTo, getJMSTimestamp, getJMSType, getLongProperty, getObjectProperty, getPropertyNames, getShortProperty, getStringProperty, isOutdated, propertyExists, readMessage, setBooleanProperty, setByteProperty, setDoubleProperty, setFloatProperty, setIntProperty, setJMSCorrelationID, setJMSCorrelationIDAsBytes, setJMSDeliveryMode, setJMSDestination, setJMSExpiration, setJMSMessageID, setJMSPriority, setJMSRedelivered, setJMSReplyTo, setJMSTimestamp, setJMSType, setLongProperty, setObjectProperty, setReadOnlyMode, setShortProperty, setStringProperty, toString, writeMessage |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface javax.jms.Message (src) |
acknowledge, 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 |
SpyObjectMessage
public SpyObjectMessage()
setObject
public void setObject(java.io.Serializable object)
throws JMSException (src)
- Description copied from interface:
ObjectMessage (src)
- Sets the serializable object containing this message's data.
It is important to note that an
ObjectMessage
contains a snapshot of the object at the time setObject()
is called; subsequent modifications of the object will have no
effect on the ObjectMessage
body.
- Specified by:
setObject
in interface ObjectMessage (src)
- Parameters:
object
- the message's data
- Throws:
JMSException (src)
- if the JMS provider fails to set the object
due to some internal error.
getObject
public java.io.Serializable getObject()
throws JMSException (src)
- Description copied from interface:
ObjectMessage (src)
- Gets the serializable object containing this message's data. The
default value is null.
- Specified by:
getObject
in interface ObjectMessage (src)
- Returns:
- the serializable object containing this message's data
- Throws:
JMSException (src)
- if the JMS provider fails to get the object
due to some internal error.
clearBody
public void clearBody()
throws JMSException (src)
- Description copied from interface:
Message (src)
- Clears out the message body. Clearing a message's body does not clear
its header values or property entries.
If this message body was read-only, calling this method leaves
the message body in the same state as an empty body in a newly
created message.
- Specified by:
clearBody
in interface Message (src)
- Overrides:
clearBody
in class SpyMessage (src)
- Throws:
JMSException (src)
- for any error
myClone
public SpyMessage (src) myClone()
throws JMSException (src)
- Description copied from class:
SpyMessage (src)
- Clone the message
- Overrides:
myClone
in class SpyMessage (src)
- Returns:
- the cloned message
- Throws:
JMSException (src)
- for any error
writeExternal
public void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
- Specified by:
writeExternal
in interface java.io.Externalizable
- Overrides:
writeExternal
in class SpyMessage (src)
- Throws:
java.io.IOException
readExternal
public void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
- Specified by:
readExternal
in interface java.io.Externalizable
- Overrides:
readExternal
in class SpyMessage (src)
- Throws:
java.io.IOException
java.lang.ClassNotFoundException