|
VR-Engage
2.2
|
This class provides a mechanism for setting and persisting information about the role a user has selected when embarking an entity. This ensures consistent role allocation when the same user reconnects to the simulation.
#include <setVreEmbarkedRole.h>
Public Member Functions | |
| DtSetVreEmbarkedRoleRequest () | |
| DtSetVreEmbarkedRoleRequest (const DtString &writeName, DtReaderWriterRegistry *parentRegistry=0) | |
| DtSetVreEmbarkedRoleRequest (const DtString &writeName, const DtSetVreEmbarkedRoleRequest &orig, DtReaderWriterRegistry *parentRegistry=0) | |
| const DtSetVreEmbarkedRoleRequest & | operator= (const DtSetVreEmbarkedRoleRequest &orig) |
| virtual | ~DtSetVreEmbarkedRoleRequest () override |
| virtual const DtSetMessageType & | type () const override |
| virtual DtSetDataRequest * | clone (const DtString &name, DtReaderWriterRegistry *parentRegistry=0) const override |
| virtual DtString | stringRep () const override |
| virtual DtString | engageEmbarkedStation () const |
| virtual void | setEngageEmbarkedStation (const DtString &station) |
| virtual int | netRepSize () const override |
| virtual bool | setFromNet (const char *contentBuffer, unsigned contentSize) override |
| virtual bool | setToNet () override |
Static Public Member Functions | |
| static DtSetDataRequest * | creator () |
Protected Attributes | |
| DtRwString | myStation |
| makVre::DtSetVreEmbarkedRoleRequest::DtSetVreEmbarkedRoleRequest | ( | ) |
Default constructor.
Initializes an empty embarked role request message.
Referenced by DtSetVreEmbarkedRoleRequest(), and operator=().
| makVre::DtSetVreEmbarkedRoleRequest::DtSetVreEmbarkedRoleRequest | ( | const DtString & | writeName, |
| DtReaderWriterRegistry * | parentRegistry = 0 ) |
Constructor with write name.
| writeName | The name to identify this request |
| parentRegistry | Optional reader-writer registry for serialization |
If you have a request 'put' itself, the writeName will preface it.
| makVre::DtSetVreEmbarkedRoleRequest::DtSetVreEmbarkedRoleRequest | ( | const DtString & | writeName, |
| const DtSetVreEmbarkedRoleRequest & | orig, | ||
| DtReaderWriterRegistry * | parentRegistry = 0 ) |
Copy constructor with new name.
| writeName | The name to identify this request |
| orig | The embarked role request to copy from |
| parentRegistry | Optional reader-writer registry for serialization |
Creates a new embarked role request by copying an existing one.
References DtSetVreEmbarkedRoleRequest().
|
overridevirtual |
Virtual destructor.
| const DtSetVreEmbarkedRoleRequest & makVre::DtSetVreEmbarkedRoleRequest::operator= | ( | const DtSetVreEmbarkedRoleRequest & | orig | ) |
Assignment operator.
| orig | The embarked role request to copy from |
Copies the contents of another embarked role request into this one.
References DtSetVreEmbarkedRoleRequest().
|
overridevirtual |
Gets the request message type.
Returns DtSetVreEmbarkedRoleType as defined in this file.
|
overridevirtual |
Creates a copy of this request.
| name | The name to assign to the new request |
| parentRegistry | Optional reader-writer registry for serialization |
Creates a dynamically allocated copy of this request with a new name.
|
overridevirtual |
Gets a readable string representation of this request.
Returns a human-readable representation of the request contents.
|
virtual |
Gets the role in which the entity was embarked.
Returns the name of the role (e.g., "gunner", "driver", "commander") that was used when embarking the entity.
|
virtual |
Sets the role in which the entity was embarked.
| station | The embarked station/role name to set |
Sets the name of the role (e.g., "gunner", "driver", "commander") that was used when embarking the entity.
|
overridevirtual |
Gets the network representation size.
Returns the size of the full network representation padded to an 8-byte boundary.
|
overridevirtual |
Deserializes the request from a network buffer.
| contentBuffer | Pointer to the network buffer |
| contentSize | Size of the buffer in bytes |
Fills in the request from the provided network buffer.
|
overridevirtual |
Serializes the request for network transmission.
Fills in the network buffer (created by base class setDataRequest) with the set data request contents.
|
static |
Static creator function for factory registration.
This static function is used for registration with the message factory.
|
protected |
The embarked station/role name.
Stores the name of the role (e.g., "gunner", "driver", "commander") that was used when embarking the entity.