TibrvMsg::getByteSize()
Method
Declaration
TibrvStatus getByteSize
(tibrv_u32& byteSize) const;
Purpose
Return the size of a message (in bytes).
Remarks
This measurement accounts for the actual space that the message occupies (in wire format), including its header and its fields. It does not include storage that is allocated but unused. It does not include address information, such as the subject or reply subject.
Programs can use this method as part of these tasks:
• | Measure the size of message before allocating space to store a copy—as with TibrvMsg::getAsBytesCopy(). |
• | Assess throughput rates. |
• | Limit output rates (also called throttling). |
Parameter |
Description |
|
The program supplies a variable. The method stores the message size (in bytes) in that variable. |