cmsg::cMsgMessage Class Reference

#include <cMsg.hxx>

List of all members.


Detailed Description

Class for wrapping cMsg message.

Definition at line 70 of file cMsg.hxx.

Public Member Functions

 cMsgMessage (void) throw (cMsgException)
 Default constructor creates message.
 cMsgMessage (const cMsgMessage &m) throw (cMsgException)
 Copy constructor creates message object from another message object.
 cMsgMessage (void *msgPointer) throw (cMsgException)
 Constructor creates message object from C message pointer.
virtual ~cMsgMessage (void)
 Destructor frees C message pointer struct.
virtual string getSubject (void) const throw (cMsgException)
 Gets message subject.
virtual void setSubject (const string &subject) throw (cMsgException)
 Sets message subject.
virtual string getType (void) const throw (cMsgException)
 Gets message type.
virtual void setType (const string &type) throw (cMsgException)
 Sets message type.
virtual string getText (void) const throw (cMsgException)
 Gets message text.
virtual void setText (const string &text) throw (cMsgException)
 Sets message text.
virtual void setByteArrayLength (int length) throw (cMsgException)
 Sets message byte array length.
virtual int getByteArrayLength (void) const throw (cMsgException)
 Gets message byte array length.
virtual void setByteArrayOffset (int offset) throw (cMsgException)
 Specifies offset in byte array.
virtual int getByteArrayOffset (void) const throw (cMsgException)
 Gets offset in byte array.
virtual int getByteArrayEndian (void) const throw (cMsgException)
 Gets endian-ness of message byte array.
virtual void setByteArrayEndian (int endian) throw (cMsgException)
 Sets endian-ness of message byte array.
virtual bool needToSwap (void) const throw (cMsgException)
 True if need to swap byte array.
virtual void setByteArray (char *array) throw (cMsgException)
 Specifies byte array.
virtual char * getByteArray (void) const throw (cMsgException)
 Gets byte array.
virtual void setByteArrayAndLimits (char *array, int offset, int length) throw (cMsgException)
 Specifies byte array, offset and length.
virtual void copyByteArray (char *array, int offset, int length) throw (cMsgException)
 Copies byte array.
virtual int getUserInt (void) const throw (cMsgException)
 Gets message user int.
virtual void setUserInt (int i) throw (cMsgException)
 Sets message user int.
virtual struct timespec getUserTime (void) const throw (cMsgException)
 Gets message user time.
virtual void setUserTime (const struct timespec &userTime) throw (cMsgException)
 Sets message user time.
virtual int getVersion (void) const throw (cMsgException)
 Gets cMsg version.
virtual string getDomain (void) const throw (cMsgException)
 Gets message domain.
virtual string getReceiver (void) const throw (cMsgException)
 Gets message receiver.
virtual string getReceiverHost (void) const throw (cMsgException)
 Gets message receiver host.
virtual string getSender (void) const throw (cMsgException)
 Gets message sender.
virtual string getSenderHost (void) const throw (cMsgException)
 Gets message sender host.
virtual struct timespec getReceiverTime (void) const throw (cMsgException)
 Gets message receiver time.
virtual struct timespec getSenderTime (void) const throw (cMsgException)
 Gets message sender time.
virtual bool isGetRequest (void) const throw (cMsgException)
 True if message is a get request.
virtual bool isGetResponse (void) const throw (cMsgException)
 True if message is a get response.
virtual bool isNullGetResponse (void) const throw (cMsgException)
 True if message is a NULL get response.
virtual void makeNullResponse (cMsgMessage &msg) throw (cMsgException)
 Makes a message a null response message.
virtual void makeNullResponse (cMsgMessage *msg) throw (cMsgException)
 Makes a message a null response message.
virtual void makeResponse (cMsgMessage &msg) throw (cMsgException)
 Makes a message a response message.
virtual void makeResponse (cMsgMessage *msg) throw (cMsgException)
 Makes a message a response message.
virtual void setGetResponse (bool b) throw (cMsgException)
 Makes message a get response message.
virtual void setNullGetResponse (bool b) throw (cMsgException)
 Makes message a null response message.
virtual string toString (void) const throw (cMsgException)
 Gets xml representation of message.
virtual cMsgMessagecopy (void) const throw (cMsgException)
 Copies a message.
virtual cMsgMessagenullResponse (void) const throw (cMsgException)
 Creates a null response message.
virtual cMsgMessageresponse (void) const throw (cMsgException)
 Creates a response message.
virtual string getSubscriptionDomain () const throw (cMsgException)
 Gets subscription domain.
virtual string getSubscriptionSubject () const throw (cMsgException)
 Gets subscription subject.
virtual string getSubscriptionType () const throw (cMsgException)
 Gets subscription type.
virtual string getSubscriptionUDL () const throw (cMsgException)
 Gets subscription UDL.
virtual int getSubscriptionCueSize (void) const throw (cMsgException)
 Gets current subscription cue size.
virtual bool getReliableSend (void) const throw (cMsgException)
 True if message sent via reliable send.
virtual void setReliableSend (bool b) throw (cMsgException)
 Sets message reliable send flag.
virtual bool hasPayload () const
 This method returns whether a message has a compound payload or not.
virtual void payloadClear (void)
 This method removes all the user-added items in the payload.
virtual void payloadWipeout (void)
 This method removes all items (including those added by the cMsg system) in the payload.
virtual void payloadPrint (void) const
 This method prints out the message payload in a readable form.
virtual void payloadCopy (cMsgMessage &msg) throw (cMsgException)
 This method copies the payload from another message.
virtual bool payloadRemoveField (const string &name)
 This method removes the named field if its exists.
virtual string payloadGetFieldDescription (const string &name) const throw (cMsgException)
 This method returns the current field name.
virtual map< string, int > * payloadGet () const throw (cMsgException)
 This method returns a pointer to a map containing all name/type pairs of the payload.
virtual int payloadGetCount () const
 This method returns the number of payload items a message has.
virtual bool payloadContainsName (const string &name) const
 This method returns whether an item in the payload has the given name or not.
virtual int payloadGetType (const string &name) const throw (cMsgException)
 This method returns the type of data associated with the payload field given by the name argument.
virtual void getBinary (string name, const char **val, int &len, int &endian) const throw (cMsgException)
 This method returns the value of the given field as a binary array if it exists.
virtual const cMsgMessagegetMessage (string name) const throw (cMsgException)
 This method returns the value of the given field as a cMsgMessage object pointer if its exists.
virtual vector< cMsgMessage > * getMessageVector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of cMsgMessage objects if its exists.
virtual string getString (string name) const throw (cMsgException)
 This method returns the value of the given field as a string if its exists.
virtual vector< string > * getStringVector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of strings if its exists.
virtual float getFloat (string name) const throw (cMsgException)
 This method returns the value of the given field as a float if its exists.
virtual double getDouble (string name) const throw (cMsgException)
 This method returns the value of the given field as a double if its exists.
virtual vector< float > * getFloatVector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of floats if its exists.
virtual vector< double > * getDoubleVector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of doubles if its exists.
virtual int8_t getInt8 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 8 bit, signed integer if its exists.
virtual int16_t getInt16 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 16 bit, signed integer if its exists.
virtual int32_t getInt32 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 32 bit, signed integer if its exists.
virtual int64_t getInt64 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 64 bit, signed integer if its exists.
virtual uint8_t getUint8 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 8 bit, unsigned integer if its exists.
virtual uint16_t getUint16 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 16 bit, unsigned integer if its exists.
virtual uint32_t getUint32 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 32 bit, unsigned integer if its exists.
virtual uint64_t getUint64 (string name) const throw (cMsgException)
 This method returns the value of the given field as an 64 bit, unsigned integer if its exists.
virtual vector< int8_t > * getInt8Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 8-bit, signed ints if its exists.
virtual vector< int16_t > * getInt16Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 16-bit, signed ints if its exists.
virtual vector< int32_t > * getInt32Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 32-bit, signed ints if its exists.
virtual vector< int64_t > * getInt64Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 64-bit, signed ints if its exists.
virtual vector< uint8_t > * getUint8Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 8-bit, unsigned ints if its exists.
virtual vector< uint16_t > * getUint16Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 16-bit, unsigned ints if its exists.
virtual vector< uint32_t > * getUint32Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 32-bit, unsigned ints if its exists.
virtual vector< uint64_t > * getUint64Vector (string name) const throw (cMsgException)
 This method returns the value of the given field as a pointer to a vector of 64-bit, unsigned ints if its exists.
virtual void addBinary (string name, const char *src, int size, int endian)
 This method adds a named binary field to the compound payload of a message.
virtual void addString (string name, string s)
 This method adds a string to the compound payload of a message.
virtual void addStringArray (string name, const char **strs, int len)
 This method adds an array of strings to the compound payload of a message.
virtual void addStringArray (string name, string *strs, int len)
 This method adds an array of strings to the compound payload of a message.
virtual void addStringVector (string name, vector< string > &strs)
 This method adds a vector of strings to the compound payload of a message.
virtual void addMessage (string name, cMsgMessage &msg)
 This method adds a cMsg message to the compound payload of a message.
virtual void addMessageArray (string name, cMsgMessage *msg, int len)
 This method adds an array of cMsg messages to the compound payload of a message.
virtual void addMessageVector (string name, vector< cMsgMessage > &msg)
 This method adds a named vector of cMsgMessage objects to the compound payload of a message.
virtual void addFloat (string name, float val)
 This method adds a named float field to the compound payload of a message.
virtual void addDouble (string name, double val)
 This method adds a named double field to the compound payload of a message.
virtual void addFloatArray (string name, float *vals, int len)
 This method adds a named array of floats to the compound payload of a message.
virtual void addDoubleArray (string name, double *vals, int len)
 This method adds a named array of doubles to the compound payload of a message.
virtual void addFloatVector (string name, vector< float > &vals)
 This method adds a named vector of floats to the compound payload of a message.
virtual void addDoubleVector (string name, vector< double > &vals)
 This method adds a named vector of doubles to the compound payload of a message.
virtual void addInt8 (string name, int8_t val)
 This method adds a named, 8-bit, signed int field to the compound payload of a message.
virtual void addInt16 (string name, int16_t val)
 This method adds a named, 16-bit, signed int field to the compound payload of a message.
virtual void addInt32 (string name, int32_t val)
 This method adds a named, 32-bit, signed int field to the compound payload of a message.
virtual void addInt64 (string name, int64_t val)
 This method adds a named, 64-bit, signed int field to the compound payload of a message.
virtual void addUint8 (string name, uint8_t val)
 This method adds a named, 8-bit, unsigned int field to the compound payload of a message.
virtual void addUint16 (string name, uint16_t val)
 This method adds a named, 16-bit, unsigned int field to the compound payload of a message.
virtual void addUint32 (string name, uint32_t val)
 This method adds a named, 32-bit, unsigned int field to the compound payload of a message.
virtual void addUint64 (string name, uint64_t val)
 This method adds a named, 64-bit, unsigned int field to the compound payload of a message.
virtual void addInt8Array (string name, int8_t *vals, int len)
 This method adds a named array of 8-bit, signed ints to the compound payload of a message.
virtual void addInt16Array (string name, int16_t *vals, int len)
 This method adds a named array of 16-bit, signed ints to the compound payload of a message.
virtual void addInt32Array (string name, int32_t *vals, int len)
 This method adds a named array of 32-bit, signed ints to the compound payload of a message.
virtual void addInt64Array (string name, int64_t *vals, int len)
 This method adds a named array of 64-bit, signed ints to the compound payload of a message.
virtual void addUint8Array (string name, uint8_t *vals, int len)
 This method adds a named array of 8-bit, unsigned ints to the compound payload of a message.
virtual void addUint16Array (string name, uint16_t *vals, int len)
 This method adds a named array of 16-bit, unsigned ints to the compound payload of a message.
virtual void addUint32Array (string name, uint32_t *vals, int len)
 This method adds a named array of 32-bit, unsigned ints to the compound payload of a message.
virtual void addUint64Array (string name, uint64_t *vals, int len)
 This method adds a named array of 64-bit, unsigned ints to the compound payload of a message.
virtual void addInt8Vector (string name, vector< int8_t > &vals)
 This method adds a named vector of 8-bit, signed ints to the compound payload of a message.
virtual void addInt16Vector (string name, vector< int16_t > &vals)
 This method adds a named vector of 16-bit, signed ints to the compound payload of a message.
virtual void addInt32Vector (string name, vector< int32_t > &vals)
 This method adds a named vector of 32-bit, signed ints to the compound payload of a message.
virtual void addInt64Vector (string name, vector< int64_t > &vals)
 This method adds a named vector of 64-bit, signed ints to the compound payload of a message.
virtual void addUint8Vector (string name, vector< uint8_t > &vals)
 This method adds a named vector of 8-bit, unsigned ints to the compound payload of a message.
virtual void addUint16Vector (string name, vector< uint16_t > &vals)
 This method adds a named vector of 16-bit, unsigned ints to the compound payload of a message.
virtual void addUint32Vector (string name, vector< uint32_t > &vals)
 This method adds a named vector of 32-bit, unsigned ints to the compound payload of a message.
virtual void addUint64Vector (string name, vector< uint64_t > &vals)
 This method adds a named vector of 64-bit, unsigned ints to the compound payload of a message.

Public Attributes

void * myMsgPointer
 Pointer to C message structure.

Friends

class cMsg
 Allows cMsg to see myMsgPointer.


Constructor & Destructor Documentation

cMsgMessage::cMsgMessage void   )  throw (cMsgException)
 

Default constructor creates message.

Definition at line 282 of file cMsgWrapper.cc.

References myMsgPointer.

Referenced by copy(), nullResponse(), and response().

cMsgMessage::cMsgMessage const cMsgMessage msg  )  throw (cMsgException)
 

Copy constructor creates message object from another message object.

Parameters:
msg The other message

Definition at line 299 of file cMsgWrapper.cc.

cMsgMessage::cMsgMessage void *  msgPointer  )  throw (cMsgException)
 

Constructor creates message object from C message pointer.

Parameters:
msgPointer C pointer to message

Definition at line 316 of file cMsgWrapper.cc.

cMsgMessage::~cMsgMessage void   )  [virtual]
 

Destructor frees C message pointer struct.

Definition at line 331 of file cMsgWrapper.cc.

References myMsgPointer.


Member Function Documentation

void cmsg::cMsgMessage::addBinary string  name,
const char *  src,
int  size,
int  endian
[virtual]
 

This method adds a named binary field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
src pointer to binary data to add
size size in bytes of data to add
endian endian value of binary data, may be CMSG_ENDIAN_BIG, CMSG_ENDIAN_LITTLE, CMSG_ENDIAN_LOCAL, or CMSG_ENDIAN_NOTLOCAL
Exceptions:
cMsgException if no memory, error in binary-to-text conversion, name already used, improper name, src is null, size < 1, or endian improper value

Definition at line 871 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addDouble string  name,
double  val
[virtual]
 

This method adds a named double field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of double to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1149 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addDoubleArray string  name,
double *  vals,
int  len
[virtual]
 

This method adds a named array of doubles to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of doubles to add (copy)
len number of doubles from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1222 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addDoubleVector string  name,
vector< double > &  vals
[virtual]
 

This method adds a named vector of doubles to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of doubles to add (copy)
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1245 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addFloat string  name,
float  val
[virtual]
 

This method adds a named float field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of float to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1126 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addFloatArray string  name,
float *  vals,
int  len
[virtual]
 

This method adds a named array of floats to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of floats to add (copy)
len number of floats from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1175 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addFloatVector string  name,
vector< float > &  vals
[virtual]
 

This method adds a named vector of floats to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of floats to add (copy)
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1198 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt16 string  name,
int16_t  val
[virtual]
 

This method adds a named, 16-bit, signed int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 16-bit, signed int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1293 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt16Array string  name,
int16_t *  vals,
int  len
[virtual]
 

This method adds a named array of 16-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 16-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1507 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt16Vector string  name,
vector< int16_t > &  vals
[virtual]
 

This method adds a named vector of 16-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 16-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1530 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt32 string  name,
int32_t  val
[virtual]
 

This method adds a named, 32-bit, signed int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 32-bit, signed int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1316 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt32Array string  name,
int32_t *  vals,
int  len
[virtual]
 

This method adds a named array of 32-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 32-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1557 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt32Vector string  name,
vector< int32_t > &  vals
[virtual]
 

This method adds a named vector of 32-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 32-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1580 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt64 string  name,
int64_t  val
[virtual]
 

This method adds a named, 64-bit, signed int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 64-bit, signed int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1339 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt64Array string  name,
int64_t *  vals,
int  len
[virtual]
 

This method adds a named array of 64-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 64-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1607 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt64Vector string  name,
vector< int64_t > &  vals
[virtual]
 

This method adds a named vector of 64-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 64-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1630 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt8 string  name,
int8_t  val
[virtual]
 

This method adds a named, 8-bit, signed int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 8-bit, signed int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1270 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt8Array string  name,
int8_t *  vals,
int  len
[virtual]
 

This method adds a named array of 8-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 8-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1457 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addInt8Vector string  name,
vector< int8_t > &  vals
[virtual]
 

This method adds a named vector of 8-bit, signed ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 8-bit, signed ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1480 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addMessage string  name,
cMsgMessage msg
[virtual]
 

This method adds a cMsg message to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
msg cMsgMessage object to add
Exceptions:
cMsgException if no memory, name already used, improper name

Definition at line 1024 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addMessageArray string  name,
cMsgMessage msg,
int  len
[virtual]
 

This method adds an array of cMsg messages to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
msg array of cMsgMessage objects to add
len number of objects from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, msg is null, len < 1

Definition at line 1047 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addMessageVector string  name,
vector< cMsgMessage > &  msg
[virtual]
 

This method adds a named vector of cMsgMessage objects to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
msg vector of cMsgMessage objects to add (copy)
Exceptions:
cMsgException if no memory, name already used, improper name

Definition at line 1087 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addString string  name,
string  s
[virtual]
 

This method adds a string to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
s string to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 896 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addStringArray string  name,
string *  strs,
int  len
[virtual]
 

This method adds an array of strings to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
strs array of strings to add
len number of strings from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, strs is null, len < 1

Definition at line 945 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addStringArray string  name,
const char **  strs,
int  len
[virtual]
 

This method adds an array of strings to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
strs array of C-style strings to add
len number of strings from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, strs is null, len < 1

Definition at line 919 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addStringVector string  name,
vector< string > &  strs
[virtual]
 

This method adds a vector of strings to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
strs vector of strings to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 985 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint16 string  name,
uint16_t  val
[virtual]
 

This method adds a named, 16-bit, unsigned int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 16-bit, unsigned int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1385 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint16Array string  name,
uint16_t *  vals,
int  len
[virtual]
 

This method adds a named array of 16-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 16-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1708 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint16Vector string  name,
vector< uint16_t > &  vals
[virtual]
 

This method adds a named vector of 16-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 16-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1731 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint32 string  name,
uint32_t  val
[virtual]
 

This method adds a named, 32-bit, unsigned int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 32-bit, unsigned int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1408 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint32Array string  name,
uint32_t *  vals,
int  len
[virtual]
 

This method adds a named array of 32-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 32-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1758 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint32Vector string  name,
vector< uint32_t > &  vals
[virtual]
 

This method adds a named vector of 32-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 32-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1781 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint64 string  name,
uint64_t  val
[virtual]
 

This method adds a named, 64-bit, unsigned int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 64-bit, unsigned int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1431 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint64Array string  name,
uint64_t *  vals,
int  len
[virtual]
 

This method adds a named array of 64-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 64-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1808 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint64Vector string  name,
vector< uint64_t > &  vals
[virtual]
 

This method adds a named vector of 64-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 64-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1831 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint8 string  name,
uint8_t  val
[virtual]
 

This method adds a named, 8-bit, unsigned int field to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
val value of 8-bit, unsigned int to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1362 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint8Array string  name,
uint8_t *  vals,
int  len
[virtual]
 

This method adds a named array of 8-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals array of 8-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, improper name, or vals is null

Definition at line 1658 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::addUint8Vector string  name,
vector< uint8_t > &  vals
[virtual]
 

This method adds a named vector of 8-bit, unsigned ints to the compound payload of a message.

Names may not begin with "cmsg" (case insensitive), be longer than CMSG_PAYLOAD_NAME_LEN, or contain white space or quotes.

Parameters:
name name of field to add
vals vector of 8-bit, unsigned ints to add (copy)
len number of ints from array to add
Exceptions:
cMsgException if no memory, name already used, or improper name

Definition at line 1681 of file cMsgPayload.cc.

References myMsgPointer.

cMsgMessage * cMsgMessage::copy void   )  const throw (cMsgException) [virtual]
 

Copies a message.

Returns:
Copy of message

Definition at line 714 of file cMsgWrapper.cc.

References cMsgMessage(), and myMsgPointer.

Here is the call graph for this function:

void cMsgMessage::copyByteArray char *  array,
int  offset,
int  length
throw (cMsgException) [virtual]
 

Copies byte array.

Parameters:
array Byte array
offset Offset in array
length Array length

Definition at line 603 of file cMsgWrapper.cc.

void cmsg::cMsgMessage::getBinary string  name,
const char **  val,
int &  len,
int &  endian
const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a binary array if it exists.

Parameters:
name name of field to get
val address of pointer to data which sets the pointer to converted binary
len int reference which gets set to the number of bytes in binary array
endian int reference which gets set to endian of data (CMSG_ENDIAN_BIG/LITTLE)
Exceptions:
cMsgException if no payload/field exists or field is not right type, or if any arg is NULL

Definition at line 264 of file cMsgPayload.cc.

char * cMsgMessage::getByteArray void   )  const throw (cMsgException) [virtual]
 

Gets byte array.

Returns:
Byte array

Definition at line 561 of file cMsgWrapper.cc.

References myMsgPointer.

int cMsgMessage::getByteArrayEndian void   )  const throw (cMsgException) [virtual]
 

Gets endian-ness of message byte array.

Returns:
Endian-ness (0=???)

Definition at line 954 of file cMsgWrapper.cc.

References myMsgPointer.

int cMsgMessage::getByteArrayLength void   )  const throw (cMsgException) [virtual]
 

Gets message byte array length.

Returns:
Array length in bytes???

Definition at line 487 of file cMsgWrapper.cc.

References myMsgPointer.

int cMsgMessage::getByteArrayOffset void   )  const throw (cMsgException) [virtual]
 

Gets offset in byte array.

Returns:
Offset in byte array

Definition at line 524 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getDomain void   )  const throw (cMsgException) [virtual]
 

Gets message domain.

Returns:
Domain

Definition at line 729 of file cMsgWrapper.cc.

References myMsgPointer.

double cmsg::cMsgMessage::getDouble string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a double if its exists.

Parameters:
name name of field to get
Returns:
field's value as a double
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 407 of file cMsgPayload.cc.

vector< double > * cmsg::cMsgMessage::getDoubleVector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of doubles if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of doubles
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 458 of file cMsgPayload.cc.

float cmsg::cMsgMessage::getFloat string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a float if its exists.

Parameters:
name name of field to get
Returns:
field's value as a float
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 388 of file cMsgPayload.cc.

vector< float > * cmsg::cMsgMessage::getFloatVector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of floats if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of floats
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 431 of file cMsgPayload.cc.

int16_t cmsg::cMsgMessage::getInt16 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 16 bit, signed integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 16-bit, signed integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 504 of file cMsgPayload.cc.

vector< int16_t > * cmsg::cMsgMessage::getInt16Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 16-bit, signed ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 16 bit, signed ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 668 of file cMsgPayload.cc.

int32_t cmsg::cMsgMessage::getInt32 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 32 bit, signed integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 32-bit, signed integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 523 of file cMsgPayload.cc.

vector< int32_t > * cmsg::cMsgMessage::getInt32Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 32-bit, signed ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 32 bit, signed ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 695 of file cMsgPayload.cc.

int64_t cmsg::cMsgMessage::getInt64 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 64 bit, signed integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 64-bit, signed integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 542 of file cMsgPayload.cc.

vector< int64_t > * cmsg::cMsgMessage::getInt64Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 64-bit, signed ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 64 bit, signed ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 722 of file cMsgPayload.cc.

int8_t cmsg::cMsgMessage::getInt8 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 8 bit, signed integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 8-bit, signed integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 485 of file cMsgPayload.cc.

vector< int8_t > * cmsg::cMsgMessage::getInt8Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 8-bit, signed ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 8 bit, signed ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 641 of file cMsgPayload.cc.

const cMsgMessage * cmsg::cMsgMessage::getMessage string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a cMsgMessage object pointer if its exists.

This object must be deleted to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as cMsg message
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 286 of file cMsgPayload.cc.

vector< cMsgMessage > * cmsg::cMsgMessage::getMessageVector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of cMsgMessage objects if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of cMsgMessage objects
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 307 of file cMsgPayload.cc.

string cMsgMessage::getReceiver void   )  const throw (cMsgException) [virtual]
 

Gets message receiver.

Returns:
Receiver

Definition at line 754 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getReceiverHost void   )  const throw (cMsgException) [virtual]
 

Gets message receiver host.

Returns:
Receiver host

Definition at line 779 of file cMsgWrapper.cc.

References myMsgPointer.

struct timespec cMsgMessage::getReceiverTime void   )  const throw (cMsgException) [virtual]
 

Gets message receiver time.

Returns:
Receiver time

Definition at line 854 of file cMsgWrapper.cc.

bool cMsgMessage::getReliableSend void   )  const throw (cMsgException) [virtual]
 

True if message sent via reliable send.

Returns:
True if reliable send used

Definition at line 1303 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getSender void   )  const throw (cMsgException) [virtual]
 

Gets message sender.

Returns:
Sender

Definition at line 804 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getSenderHost void   )  const throw (cMsgException) [virtual]
 

Gets message sender host.

Returns:
Sender host

Definition at line 829 of file cMsgWrapper.cc.

References myMsgPointer.

struct timespec cMsgMessage::getSenderTime void   )  const throw (cMsgException) [virtual]
 

Gets message sender time.

Returns:
Sender time

Definition at line 874 of file cMsgWrapper.cc.

string cmsg::cMsgMessage::getString string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a string if its exists.

Parameters:
name name of field to get
Returns:
field's value as string
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 338 of file cMsgPayload.cc.

vector< string > * cmsg::cMsgMessage::getStringVector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of strings if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of strings
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 360 of file cMsgPayload.cc.

string cMsgMessage::getSubject void   )  const throw (cMsgException) [virtual]
 

Gets message subject.

Returns:
Message subject

Definition at line 344 of file cMsgWrapper.cc.

References myMsgPointer.

int cMsgMessage::getSubscriptionCueSize void   )  const throw (cMsgException) [virtual]
 

Gets current subscription cue size.

Returns:
Current cue size

Definition at line 1283 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getSubscriptionDomain void   )  const throw (cMsgException) [virtual]
 

Gets subscription domain.

Returns:
Subscription domain

Definition at line 1183 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getSubscriptionSubject void   )  const throw (cMsgException) [virtual]
 

Gets subscription subject.

Returns:
Subscription subject

Definition at line 1208 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getSubscriptionType void   )  const throw (cMsgException) [virtual]
 

Gets subscription type.

Returns:
Subscription type

Definition at line 1233 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getSubscriptionUDL void   )  const throw (cMsgException) [virtual]
 

Gets subscription UDL.

Returns:
Subscription UDL

Definition at line 1258 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getText void   )  const throw (cMsgException) [virtual]
 

Gets message text.

Returns:
Message text

Definition at line 428 of file cMsgWrapper.cc.

References myMsgPointer.

string cMsgMessage::getType void   )  const throw (cMsgException) [virtual]
 

Gets message type.

Returns:
Message type

Definition at line 386 of file cMsgWrapper.cc.

References myMsgPointer.

uint16_t cmsg::cMsgMessage::getUint16 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 16 bit, unsigned integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 16-bit, unsigned integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 580 of file cMsgPayload.cc.

vector< uint16_t > * cmsg::cMsgMessage::getUint16Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 16-bit, unsigned ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 16 bit, unsigned ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 778 of file cMsgPayload.cc.

uint32_t cmsg::cMsgMessage::getUint32 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 32 bit, unsigned integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 32-bit, unsigned integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 599 of file cMsgPayload.cc.

vector< uint32_t > * cmsg::cMsgMessage::getUint32Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 32-bit, unsigned ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 32 bit, unsigned ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 805 of file cMsgPayload.cc.

uint64_t cmsg::cMsgMessage::getUint64 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 64 bit, unsigned integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 64-bit, unsigned integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 618 of file cMsgPayload.cc.

vector< uint64_t > * cmsg::cMsgMessage::getUint64Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 64-bit, unsigned ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 64 bit, unsigned ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 832 of file cMsgPayload.cc.

uint8_t cmsg::cMsgMessage::getUint8 string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as an 8 bit, unsigned integer if its exists.

Parameters:
name name of field to get
Returns:
field's value as an 8-bit, unsigned integer
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 561 of file cMsgPayload.cc.

vector< uint8_t > * cmsg::cMsgMessage::getUint8Vector string  name  )  const throw (cMsgException) [virtual]
 

This method returns the value of the given field as a pointer to a vector of 8-bit, unsigned ints if its exists.

The vector pointer must be deleted by caller to avoid a memory leak.

Parameters:
name name of field to get
Returns:
field's value as vector of 8 bit, unsigned ints
Exceptions:
cMsgException if no payload/field exists or field is not right type

Definition at line 750 of file cMsgPayload.cc.

int cMsgMessage::getUserInt void   )  const throw (cMsgException) [virtual]
 

Gets message user int.

Returns:
User int

Definition at line 620 of file cMsgWrapper.cc.

References myMsgPointer.

struct timespec cMsgMessage::getUserTime void   )  const throw (cMsgException) [virtual]
 

Gets message user time.

Returns:
Timespec holding user time

Definition at line 657 of file cMsgWrapper.cc.

int cMsgMessage::getVersion void   )  const throw (cMsgException) [virtual]
 

Gets cMsg version.

Returns:
Version

Definition at line 694 of file cMsgWrapper.cc.

References myMsgPointer.

bool cmsg::cMsgMessage::hasPayload  )  const [virtual]
 

This method returns whether a message has a compound payload or not.

Returns:
true if message has a payload, else false

Definition at line 78 of file cMsgPayload.cc.

References myMsgPointer.

bool cMsgMessage::isGetRequest void   )  const throw (cMsgException) [virtual]
 

True if message is a get request.

Returns:
True if get request

Definition at line 894 of file cMsgWrapper.cc.

References myMsgPointer.

bool cMsgMessage::isGetResponse void   )  const throw (cMsgException) [virtual]
 

True if message is a get response.

Returns:
True if get response

Definition at line 914 of file cMsgWrapper.cc.

References myMsgPointer.

bool cMsgMessage::isNullGetResponse void   )  const throw (cMsgException) [virtual]
 

True if message is a NULL get response.

Returns:
True if NULL get response

Definition at line 934 of file cMsgWrapper.cc.

References myMsgPointer.

void cMsgMessage::makeNullResponse cMsgMessage msg  )  throw (cMsgException) [virtual]
 

Makes a message a null response message.

Parameters:
msg Message to make a null response

Definition at line 1032 of file cMsgWrapper.cc.

void cMsgMessage::makeNullResponse cMsgMessage msg  )  throw (cMsgException) [virtual]
 

Makes a message a null response message.

Parameters:
msg Message to make a null response

Definition at line 1013 of file cMsgWrapper.cc.

void cMsgMessage::makeResponse cMsgMessage msg  )  throw (cMsgException) [virtual]
 

Makes a message a response message.

Parameters:
msg Message to make a response

Definition at line 1070 of file cMsgWrapper.cc.

void cMsgMessage::makeResponse cMsgMessage msg  )  throw (cMsgException) [virtual]
 

Makes a message a response message.

Parameters:
msg Message to make a response

Definition at line 1051 of file cMsgWrapper.cc.

bool cMsgMessage::needToSwap void   )  const throw (cMsgException) [virtual]
 

True if need to swap byte array.

Returns:
True if must swap

Definition at line 993 of file cMsgWrapper.cc.

References myMsgPointer.

cMsgMessage * cMsgMessage::nullResponse void   )  const throw (cMsgException) [virtual]
 

Creates a null response message.

Returns:
Null response message

Definition at line 1089 of file cMsgWrapper.cc.

References cMsgMessage(), and myMsgPointer.

Here is the call graph for this function:

void cmsg::cMsgMessage::payloadClear void   )  [virtual]
 

This method removes all the user-added items in the payload.

The payload may still contain fields added by the cMsg system. If there are no items left in the payload, this method is equivalent to cMsgMessage#payloadWipeout.

Definition at line 46 of file cMsgPayload.cc.

References myMsgPointer.

bool cmsg::cMsgMessage::payloadContainsName const string &  name  )  const [virtual]
 

This method returns whether an item in the payload has the given name or not.

Parameters:
name name of field to look for
Returns:
true if an item in the payload has the given name, else false

Definition at line 92 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::payloadCopy cMsgMessage msg  )  throw (cMsgException) [virtual]
 

This method copies the payload from another message.

The original payload is overwritten.

Parameters:
reference to message to copy payload from
Exceptions:
cMsgException if no memory

Definition at line 172 of file cMsgPayload.cc.

map< string, int > * cmsg::cMsgMessage::payloadGet  )  const throw (cMsgException) [virtual]
 

This method returns a pointer to a map containing all name/type pairs of the payload.

A field's name is the key and type is the value. The map must be deleted to avoid a memory leak.

Returns:
a pointer to a map containing all name/type pairs of the payload
Exceptions:
cMsgException if no payload exists, or if name is NULL

Definition at line 209 of file cMsgPayload.cc.

References myMsgPointer.

int cmsg::cMsgMessage::payloadGetCount  )  const [virtual]
 

This method returns the number of payload items a message has.

Returns:
number of payload items a message has

Definition at line 103 of file cMsgPayload.cc.

References myMsgPointer.

string cmsg::cMsgMessage::payloadGetFieldDescription const string &  name  )  const throw (cMsgException) [virtual]
 

This method returns the current field name.

Exceptions:
cMsgException if no payload

Definition at line 186 of file cMsgPayload.cc.

int cmsg::cMsgMessage::payloadGetType const string &  name  )  const throw (cMsgException) [virtual]
 

This method returns the type of data associated with the payload field given by the name argument.

The returned type may have the following values:

  • CMSG_CP_STR for a String
  • CMSG_CP_FLT for a 4 byte float
  • CMSG_CP_DBL for an 8 byte float
  • CMSG_CP_INT8 for an 8 bit int
  • CMSG_CP_INT16 for a 16 bit int
  • CMSG_CP_INT32 for a 32 bit int
  • CMSG_CP_INT64 for a 64 bit int
  • CMSG_CP_UINT8 for an unsigned 8 bit int
  • CMSG_CP_UINT16 for an unsigned 16 bit int
  • CMSG_CP_UINT32 for an unsigned 32 bit int
  • CMSG_CP_UINT64 for an unsigned 64 bit int
  • CMSG_CP_MSG for a cMsg message
  • CMSG_CP_BIN for binary

  • CMSG_CP_STR_A for a String array
  • CMSG_CP_FLT_A for a 4 byte float array
  • CMSG_CP_DBL_A for an 8 byte float array
  • CMSG_CP_INT8_A for an 8 bit int array
  • CMSG_CP_INT16_A for a 16 bit int array
  • CMSG_CP_INT32_A for a 32 bit int array
  • CMSG_CP_INT64_A for a 64 bit int array
  • CMSG_CP_UINT8_A for an unsigned 8 bit int array
  • CMSG_CP_UINT16_A for an unsigned 16 bit int array
  • CMSG_CP_UINT32_A for an unsigned 32 bit int array
  • CMSG_CP_UINT64_A for an unsigned 64 bit int array
  • CMSG_CP_MSG_A for a cMsg message array

Parameters:
name name of field to find type for
Returns:
the type of data associated with the payload field given by the name argument
Exceptions:
cMsgException if no payload/field exists, or if name is NULL

Definition at line 150 of file cMsgPayload.cc.

void cmsg::cMsgMessage::payloadPrint void   )  const [virtual]
 

This method prints out the message payload in a readable form.

Definition at line 67 of file cMsgPayload.cc.

References myMsgPointer.

bool cmsg::cMsgMessage::payloadRemoveField const string &  name  )  [virtual]
 

This method removes the named field if its exists.

Parameters:
name name of field to remove
Returns:
true if successful

false if no field with that name was found

Definition at line 240 of file cMsgPayload.cc.

References myMsgPointer.

void cmsg::cMsgMessage::payloadWipeout void   )  [virtual]
 

This method removes all items (including those added by the cMsg system) in the payload.

This method frees the allocated memory of the given message's entire payload and then initializes the payload components of the message.

Definition at line 58 of file cMsgPayload.cc.

References myMsgPointer.

cMsgMessage * cMsgMessage::response void   )  const throw (cMsgException) [virtual]
 

Creates a response message.

Returns:
Response message

Definition at line 1108 of file cMsgWrapper.cc.

References cMsgMessage(), and myMsgPointer.

Here is the call graph for this function:

void cMsgMessage::setByteArray char *  array  )  throw (cMsgException) [virtual]
 

Specifies byte array.

Parameters:
array Byte array

Definition at line 544 of file cMsgWrapper.cc.

void cMsgMessage::setByteArrayAndLimits char *  array,
int  offset,
int  length
throw (cMsgException) [virtual]
 

Specifies byte array, offset and length.

Parameters:
array Byte array
offset Offset in array
length Array length

Definition at line 584 of file cMsgWrapper.cc.

void cMsgMessage::setByteArrayEndian int  endian  )  throw (cMsgException) [virtual]
 

Sets endian-ness of message byte array.

Parameters:
endian Endian-ness (0=???)

Definition at line 974 of file cMsgWrapper.cc.

void cMsgMessage::setByteArrayLength int  length  )  throw (cMsgException) [virtual]
 

Sets message byte array length.

Parameters:
length Array length in bytes???

Definition at line 470 of file cMsgWrapper.cc.

void cMsgMessage::setByteArrayOffset int  offset  )  throw (cMsgException) [virtual]
 

Specifies offset in byte array.

Parameters:
offset Offset in byte array

Definition at line 507 of file cMsgWrapper.cc.

void cMsgMessage::setGetResponse bool  b  )  throw (cMsgException) [virtual]
 

Makes message a get response message.

Parameters:
b True to make message a get response message

Definition at line 1127 of file cMsgWrapper.cc.

void cMsgMessage::setNullGetResponse bool  b  )  throw (cMsgException) [virtual]
 

Makes message a null response message.

Parameters:
b True to make message a null response message

Definition at line 1144 of file cMsgWrapper.cc.

void cMsgMessage::setReliableSend bool  b  )  throw (cMsgException) [virtual]
 

Sets message reliable send flag.

Parameters:
b True if reliable send should be used

Definition at line 1323 of file cMsgWrapper.cc.

void cMsgMessage::setSubject const string &  subject  )  throw (cMsgException) [virtual]
 

Sets message subject.

Parameters:
subject Message subject

Definition at line 369 of file cMsgWrapper.cc.

void cMsgMessage::setText const string &  text  )  throw (cMsgException) [virtual]
 

Sets message text.

Parameters:
text Message text

Definition at line 453 of file cMsgWrapper.cc.

void cMsgMessage::setType const string &  type  )  throw (cMsgException) [virtual]
 

Sets message type.

Parameters:
type Message type

Definition at line 411 of file cMsgWrapper.cc.

void cMsgMessage::setUserInt int  i  )  throw (cMsgException) [virtual]
 

Sets message user int.

Parameters:
i User int

Definition at line 640 of file cMsgWrapper.cc.

void cMsgMessage::setUserTime const struct timespec &  userTime  )  throw (cMsgException) [virtual]
 

Sets message user time.

Parameters:
userTime Timespec holding user time

Definition at line 677 of file cMsgWrapper.cc.

string cMsgMessage::toString void   )  const throw (cMsgException) [virtual]
 

Gets xml representation of message.

Returns:
xml representation of message

Definition at line 1161 of file cMsgWrapper.cc.

References myMsgPointer.


Friends And Related Function Documentation

friend class cMsg [friend]
 

Allows cMsg to see myMsgPointer.

Definition at line 72 of file cMsg.hxx.


Member Data Documentation

void* cmsg::cMsgMessage::myMsgPointer
 

Pointer to C message structure.

Definition at line 238 of file cMsg.hxx.

Referenced by addBinary(), addDouble(), addDoubleArray(), addDoubleVector(), addFloat(), addFloatArray(), addFloatVector(), addInt16(), addInt16Array(), addInt16Vector(), addInt32(), addInt32Array(), addInt32Vector(), addInt64(), addInt64Array(), addInt64Vector(), addInt8(), addInt8Array(), addInt8Vector(), addMessage(), addMessageArray(), addMessageVector(), addString(), addStringArray(), addStringVector(), addUint16(), addUint16Array(), addUint16Vector(), addUint32(), addUint32Array(), addUint32Vector(), addUint64(), addUint64Array(), addUint64Vector(), addUint8(), addUint8Array(), addUint8Vector(), cMsgMessage(), copy(), getByteArray(), getByteArrayEndian(), getByteArrayLength(), getByteArrayOffset(), getDomain(), getReceiver(), getReceiverHost(), getReliableSend(), getSender(), getSenderHost(), getSubject(), getSubscriptionCueSize(), getSubscriptionDomain(), getSubscriptionSubject(), getSubscriptionType(), getSubscriptionUDL(), getText(), getType(), getUserInt(), getVersion(), hasPayload(), isGetRequest(), isGetResponse(), isNullGetResponse(), needToSwap(), nullResponse(), payloadClear(), payloadContainsName(), payloadGet(), payloadGetCount(), payloadPrint(), payloadRemoveField(), payloadWipeout(), response(), toString(), and ~cMsgMessage().


The documentation for this class was generated from the following files:
Generated on Wed Feb 6 13:37:50 2008 for cMsg Messaging System by  doxygen 1.3.9.1