org.mockejb.jms
Class ObjectMessageImpl

java.lang.Object
  extended byorg.mockejb.jms.MessageImpl
      extended byorg.mockejb.jms.ObjectMessageImpl
All Implemented Interfaces:
javax.jms.Message, javax.jms.ObjectMessage

public class ObjectMessageImpl
extends MessageImpl
implements javax.jms.ObjectMessage

ObjectMessage implementation.

Author:
Dimitar Gospodinov
See Also:
ObjectMessage

Field Summary
 
Fields inherited from interface javax.jms.Message
DEFAULT_DELIVERY_MODE, DEFAULT_PRIORITY, DEFAULT_TIME_TO_LIVE
 
Constructor Summary
ObjectMessageImpl()
          Creates empty ObjectMessageImpl.
ObjectMessageImpl(javax.jms.ObjectMessage msg)
          Creates new ObjectMessageImpl and sets its header, properties and body to the corresponded values from msg
ObjectMessageImpl(java.io.Serializable object)
          Creates new ObjectMessageImpl and sets its body to object
 
Method Summary
 void clearBody()
           
 java.io.Serializable getObject()
           
 void setObject(java.io.Serializable object)
           
 
Methods inherited from class org.mockejb.jms.MessageImpl
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, setPropertiesNotWriteable, setShortProperty, setStringProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.jms.Message
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
 

Constructor Detail

ObjectMessageImpl

public ObjectMessageImpl()
Creates empty ObjectMessageImpl.


ObjectMessageImpl

public ObjectMessageImpl(java.io.Serializable object)
                  throws javax.jms.JMSException
Creates new ObjectMessageImpl and sets its body to object

Parameters:
object -
Throws:
javax.jms.JMSException

ObjectMessageImpl

public ObjectMessageImpl(javax.jms.ObjectMessage msg)
                  throws javax.jms.JMSException
Creates new ObjectMessageImpl and sets its header, properties and body to the corresponded values from msg

Parameters:
msg -
Throws:
javax.jms.JMSException
Method Detail

setObject

public void setObject(java.io.Serializable object)
               throws javax.jms.JMSException
Specified by:
setObject in interface javax.jms.ObjectMessage
Throws:
javax.jms.JMSException
See Also:
ObjectMessage.setObject(java.io.Serializable)

getObject

public java.io.Serializable getObject()
                               throws javax.jms.JMSException
Specified by:
getObject in interface javax.jms.ObjectMessage
Throws:
javax.jms.JMSException
See Also:
ObjectMessage.getObject()

clearBody

public void clearBody()
               throws javax.jms.JMSException
Specified by:
clearBody in interface javax.jms.Message
Overrides:
clearBody in class MessageImpl
Throws:
javax.jms.JMSException
See Also:
Message.clearBody()