activemq-cpp-3.4.0
|
Interface for a text message. More...
#include <src/main/cms/TextMessage.h>
Public Member Functions | |
virtual | ~TextMessage () throw () |
virtual std::string | getText () const =0 |
Gets the message character buffer. | |
virtual void | setText (const char *msg)=0 |
Sets the message contents, does not take ownership of the passed char*, but copies it instead. | |
virtual void | setText (const std::string &msg)=0 |
Sets the message contents. |
Interface for a text message.
A TextMessage can contain any Text based pay load such as an XML Document or other Text based document.
Like all Messages, a TextMessage is received in Read-Only mode, any attempt to write to the Message will result in a MessageNotWritableException being thrown until the clearBody
method is called which will erase the contents and place the message back in a read / write mode.
virtual cms::TextMessage::~TextMessage | ( | ) | throw () [virtual] |
virtual std::string cms::TextMessage::getText | ( | ) | const [pure virtual] |
Gets the message character buffer.
CMSException | - if an internal error occurs. |
Implemented in activemq::commands::ActiveMQTextMessage.
virtual void cms::TextMessage::setText | ( | const std::string & | msg | ) | [pure virtual] |
Sets the message contents.
msg | The message buffer. |
CMSException | - if an internal error occurs. |
MessageNotWriteableException | - if the message is in read-only mode.. |
Implemented in activemq::commands::ActiveMQTextMessage.
virtual void cms::TextMessage::setText | ( | const char * | msg | ) | [pure virtual] |
Sets the message contents, does not take ownership of the passed char*, but copies it instead.
msg | The message buffer. |
CMSException | - if an internal error occurs. |
MessageNotWriteableException | - if the message is in read-only mode.. |
Implemented in activemq::commands::ActiveMQTextMessage.