activemq-cpp-3.9.0
cms::ObjectMessage Class Referenceabstract

Place holder for interaction with JMS systems that support Java, the C++ client is not responsible for deserializing the contained Object. More...

#include <src/main/cms/ObjectMessage.h>

Inheritance diagram for cms::ObjectMessage:

Public Member Functions

virtual ~ObjectMessage ()
 
virtual void setObjectBytes (const std::vector< unsigned char > &bytes)=0
 Sets the payload bytes the represent the Object being transmitted. More...
 
virtual std::vector< unsigned
char > 
getObjectBytes () const =0
 Returns the byte array containing the serialized form of the transmitted Object. More...
 
- Public Member Functions inherited from cms::Message
virtual ~Message ()
 
virtual Messageclone () const =0
 Clone this message exactly, returns a new instance that the caller is required to delete. More...
 
virtual void acknowledge () const =0
 Acknowledges all consumed messages of the session of this consumed message. More...
 
virtual void clearBody ()=0
 Clears out the body of the message. More...
 
virtual void clearProperties ()=0
 Clears out the message body. More...
 
virtual std::vector< std::string > getPropertyNames () const =0
 Retrieves the property names. More...
 
virtual bool propertyExists (const std::string &name) const =0
 Indicates whether or not a given property exists. More...
 
virtual ValueType getPropertyValueType (const std::string &name) const =0
 Returns the value type for the given property key. More...
 
virtual bool getBooleanProperty (const std::string &name) const =0
 Gets a boolean property. More...
 
virtual unsigned char getByteProperty (const std::string &name) const =0
 Gets a byte property. More...
 
virtual double getDoubleProperty (const std::string &name) const =0
 Gets a double property. More...
 
virtual float getFloatProperty (const std::string &name) const =0
 Gets a float property. More...
 
virtual int getIntProperty (const std::string &name) const =0
 Gets a int property. More...
 
virtual long long getLongProperty (const std::string &name) const =0
 Gets a long property. More...
 
virtual short getShortProperty (const std::string &name) const =0
 Gets a short property. More...
 
virtual std::string getStringProperty (const std::string &name) const =0
 Gets a string property. More...
 
virtual void setBooleanProperty (const std::string &name, bool value)=0
 Sets a boolean property. More...
 
virtual void setByteProperty (const std::string &name, unsigned char value)=0
 Sets a byte property. More...
 
virtual void setDoubleProperty (const std::string &name, double value)=0
 Sets a double property. More...
 
virtual void setFloatProperty (const std::string &name, float value)=0
 Sets a float property. More...
 
virtual void setIntProperty (const std::string &name, int value)=0
 Sets a int property. More...
 
virtual void setLongProperty (const std::string &name, long long value)=0
 Sets a long property. More...
 
virtual void setShortProperty (const std::string &name, short value)=0
 Sets a short property. More...
 
virtual void setStringProperty (const std::string &name, const std::string &value)=0
 Sets a string property. More...
 
virtual std::string getCMSCorrelationID () const =0
 Gets the correlation ID for the message. More...
 
virtual void setCMSCorrelationID (const std::string &correlationId)=0
 Sets the correlation ID for the message. More...
 
virtual int getCMSDeliveryMode () const =0
 Gets the DeliveryMode for this message. More...
 
virtual void setCMSDeliveryMode (int mode)=0
 Sets the DeliveryMode for this message. More...
 
virtual const DestinationgetCMSDestination () const =0
 Gets the Destination object for this message. More...
 
virtual void setCMSDestination (const Destination *destination)=0
 Sets the Destination object for this message. More...
 
virtual long long getCMSExpiration () const =0
 Gets the message's expiration value. More...
 
virtual void setCMSExpiration (long long expireTime)=0
 Sets the message's expiration value. More...
 
virtual std::string getCMSMessageID () const =0
 The CMSMessageID header field contains a value that uniquely identifies each message sent by a provider. More...
 
virtual void setCMSMessageID (const std::string &id)=0
 Sets the message ID. More...
 
virtual int getCMSPriority () const =0
 Gets the message priority level. More...
 
virtual void setCMSPriority (int priority)=0
 Sets the Priority Value for this message. More...
 
virtual bool getCMSRedelivered () const =0
 Gets an indication of whether this message is being redelivered. More...
 
virtual void setCMSRedelivered (bool redelivered)=0
 Specifies whether this message is being redelivered. More...
 
virtual const cms::DestinationgetCMSReplyTo () const =0
 Gets the Destination object to which a reply to this message should be sent. More...
 
virtual void setCMSReplyTo (const cms::Destination *destination)=0
 Sets the Destination object to which a reply to this message should be sent. More...
 
virtual long long getCMSTimestamp () const =0
 Gets the message timestamp. More...
 
virtual void setCMSTimestamp (long long timeStamp)=0
 Sets the message timestamp. More...
 
virtual std::string getCMSType () const =0
 Gets the message type identifier supplied by the client when the message was sent. More...
 
virtual void setCMSType (const std::string &type)=0
 Sets the message type. More...
 

Additional Inherited Members

- Public Types inherited from cms::Message
enum  ValueType {
  NULL_TYPE = 0, BOOLEAN_TYPE = 1, BYTE_TYPE = 2, CHAR_TYPE = 3,
  SHORT_TYPE = 4, INTEGER_TYPE = 5, LONG_TYPE = 6, DOUBLE_TYPE = 7,
  FLOAT_TYPE = 8, STRING_TYPE = 9, BYTE_ARRAY_TYPE = 10, UNKNOWN_TYPE = 11
}
 Defines the Type Identifiers used to identify the type contained within a specific Message property or MapMessage keyed value. More...
 
- Static Public Attributes inherited from cms::Message
static const int DEFAULT_DELIVERY_MODE
 The Default delivery mode for Message Producers is PERSISTENT. More...
 
static const int DEFAULT_MSG_PRIORITY
 The Default priority assigned to a Message is 4. More...
 
static const long long DEFAULT_TIME_TO_LIVE
 The Default Time to Live for a Message Producer is unlimited, the message will never expire. More...
 

Detailed Description

Place holder for interaction with JMS systems that support Java, the C++ client is not responsible for deserializing the contained Object.

The Object can be accessed in its serialized form as a vector of bytes which allows for bridging of message systems.

serialized ObjectMessages.

Since
1.0

Constructor & Destructor Documentation

virtual cms::ObjectMessage::~ObjectMessage ( )
virtual

Member Function Documentation

virtual std::vector<unsigned char> cms::ObjectMessage::getObjectBytes ( ) const
pure virtual

Returns the byte array containing the serialized form of the transmitted Object.

Returns
a byte vector containing the serialized Object.
Exceptions
CMSException- if the operation fails due to an internal error.
MessageNotReadableException- if the message is in write only mode.

Implemented in activemq::commands::ActiveMQObjectMessage.

virtual void cms::ObjectMessage::setObjectBytes ( const std::vector< unsigned char > &  bytes)
pure virtual

Sets the payload bytes the represent the Object being transmitted.

Parameters
bytesThe byte array that contains the serialized object.
Exceptions
CMSException- if the operation fails due to an internal error.
MessageNotWriteableException- if the Message is in Read-only Mode.

Implemented in activemq::commands::ActiveMQObjectMessage.


The documentation for this class was generated from the following file: