![]() |
VR-Link API Documentation for HLA 1.3
|
A bass class for PDUs and other network messages. More...
Inheritance diagram for DtBaseMsg:
Collaboration diagram for DtBaseMsg:Public Member Functions | |
| virtual | ~DtBaseMsg () |
| Destructor. More... | |
| DtBaseMsg (const DtBaseMsg &msg, DtBufferPtr buffer=DtUSE_INTERNAL_BUFFER) | |
| Copy constructor. More... | |
| DtBaseMsg & | operator= (const DtBaseMsg &msg) |
| Assignment. More... | |
| virtual const char * | netRep () const |
| Get network representation. More... | |
| virtual int | length () const |
| Get size of message. More... | |
| DtBaseMsg () | |
| Constructor Object is not fully constructed until initMsg is called. More... | |
| void | initMsg (int size, DtBufferPtr bufferPtr) |
| void | initMsg (const void *initial, int size, DtBufferPtr bufferPtr) |
| virtual void | changeSize (int size) |
| Changes the size of the message. More... | |
| virtual void | changeBufferSize (int size) |
| Changes the size of the message buffer, but not the message itself. More... | |
| virtual void | insertBytes (int offset, int numBytes) |
| Inserts numBytes zeroed-out bytes at the indicated offset into the net rep. More... | |
| virtual void | insertBytes (void *address, int numBytes) |
| Inserts numBytes zeroed-out bytes at the indicated address. More... | |
| virtual void | deleteBytes (int offset, int numBytes) |
| Deletes numBytes bytes at the indicated offset in the net rep. More... | |
| virtual void | deleteBytes (void *address, int numBytes) |
| Deletes numBytes bytes starting at the indicated address. More... | |
| virtual void | clearAll () |
| Zeros out all bytes in the network representation. More... | |
| virtual void * | newInternalBuffer (int size) |
| Sets myInternalBuff to point to a malloc'ed buffer of size bytes. More... | |
| virtual void | sizeChanged (int size)=0 |
| Called by changeSize. More... | |
Protected Attributes | |
| void * | myNetMsg |
| void * | myInternalBuff |
| int | myIntBuffSize |
| int | myMsgSize |
| int | myNetworkMsgSize |
A bass class for PDUs and other network messages.
|
virtual |
Destructor.
| DtBaseMsg::DtBaseMsg | ( | const DtBaseMsg & | msg, |
| DtBufferPtr | buffer = DtUSE_INTERNAL_BUFFER |
||
| ) |
Copy constructor.
| DtBaseMsg::DtBaseMsg | ( | ) |
Constructor Object is not fully constructed until initMsg is called.
|
virtual |
Changes the size of the message buffer, but not the message itself.
Can be used when you want to allocate space for a coupled message to be sent with the primary message while not changing the size of the primary message itself.
|
virtual |
Changes the size of the message.
If we are using an external buffer, assumes that the full buffer size is big enough to accommodate the new msg size. If using an internal buffer, the call may result in allocating a new internal buffer, and copying data from the old to the new buffer.
|
virtual |
Zeros out all bytes in the network representation.
|
virtual |
Deletes numBytes bytes at the indicated offset in the net rep.
Uses change size to decrease the size of the buffer.
|
virtual |
Deletes numBytes bytes starting at the indicated address.
Assumes that address falls within the net rep. Uses changeSize to decrease the size of the buffer.
| void DtBaseMsg::initMsg | ( | int | size, |
| DtBufferPtr | bufferPtr | ||
| ) |
| void DtBaseMsg::initMsg | ( | const void * | initial, |
| int | size, | ||
| DtBufferPtr | bufferPtr | ||
| ) |
|
virtual |
Inserts numBytes zeroed-out bytes at the indicated offset into the net rep.
Uses changeSize to increase the size of the buffer.
|
virtual |
Inserts numBytes zeroed-out bytes at the indicated address.
Assumes that address falls within the net rep. Uses changeSize to increase the size of the buffer.
|
virtual |
Get size of message.
Referenced by DtPdu::setPduLength().
|
inlinevirtual |
Get network representation.
Referenced by DtDatumRecordSet::netDataRep(), DtPdu::netHeader(), and DtPdu::packet().
|
virtual |
Sets myInternalBuff to point to a malloc'ed buffer of size bytes.
Sets myIntBuffSize to size. Returns myInternalBuff. Size must be a positive number.
|
pure virtual |
Called by changeSize.
Derived versions can provide definitions that set the size field in network rep.
Implemented in DtDatumRecordSet, and DtPdu.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |