#include <DataBlock_NData.h>


Public Member Functions | |
| DataBlock_NData () | |
| virtual | ~DataBlock_NData () |
| virtual void | Poll (DataBlockReason *reason) |
| virtual void | ParseMessage (MessageHelper *message) |
| void | RegisterInClassPointer (void *const data, const int size) |
| void | SetDefaultData (const void *data) |
| bool | IsAttached (void *data) |
| void | SetEndianTest (const bool test=true) |
| bool | GetEndianTest (void) const |
Static Public Member Functions | |
| static DataBlock_NData * | Register (void *const data, const int size) |
Protected Attributes | |
| void * | mData |
| int | mSize |
|
RegistryManagerMap < int, SessionBlock_NData > | mPerSessionData |
| void * | mDefaultData |
| bool | mDisableEndian |
Classes | |
| struct | SessionBlock_NData |
| DataBlock_NData | ( | ) |
The ctor performs some basic initialisation
| virtual ~DataBlock_NData | ( | ) | [virtual] |
The dtor makes sure everything is tidy
| virtual void Poll | ( | DataBlockReason * | reason | ) | [virtual] |
A poll function that is called by ReplicaNet to check for updates to this particular data block. If this virtual method is implemented by a derived class this base class method should be called before a data packet is created. Processing for this function may occur during the thread context of ReplicaNet so processing time used by this function should be kept to a minimum to avoid performance issues.
| reason | the reason code that is passed in to this class to enable a response to be calculated |
Reimplemented from DataBlock.
| virtual void ParseMessage | ( | MessageHelper * | message | ) | [virtual] |
This parses a message for the derived class of this data block. Processing for this function may occur during the thread context of ReplicaNet so processing time used by this function should be kept to a minimum to avoid performance issues.
| message | The current message buffer that contains the packet data |
Reimplemented from DataBlock.
| static DataBlock_NData* Register | ( | void *const | data, | |
| const int | size | |||
| ) | [static] |
This registers the memory area with this data block type and returns a new pointer
| data | the start of the memory to check | |
| size | the size of the data block |
| void RegisterInClassPointer | ( | void *const | data, | |
| const int | size | |||
| ) | [inline] |
This registers the memory area with this data block type. This is used when the memory is in datablocks that are allocated as part of a bigger class.
| data | the start of the memory to check | |
| size | the size of the data block |
| void SetDefaultData | ( | const void * | data | ) |
This allows a block of memory to be passed in that shows a default state of the data block. This default memory state is copied so it can be temporary. When a session joins or an object is created, the datablock states are serialised. By setting a default state the user can avoid the extra data being sent out for the datablock state.
| data | the pointer to the memory. |
| bool IsAttached | ( | void * | data | ) | [virtual] |
Given a data pointer this function identifies if this data block is attached to the pointer.
Reimplemented from DataBlock.
1.5.3