#include <mdtype.h>
Inheritance diagram for MDValue:
Public Member Functions | |
MDValue (const std::string &BaseType) | |
MDValue named constructor. | |
MDValue (MDTypePtr BaseType) | |
MDValue typed constructor. | |
void | Init (void) |
Second part of MDValue constructors. | |
~MDValue () | |
void | AddChild (MDValuePtr Child, int Index=-1) |
Add a child to an MDValue continer. | |
void | Resize (UInt32 Index) |
Add or Remove children from an MDValue continer to make a fixed size. | |
MDValuePtr | operator[] (int Index) |
Access array member within an MDValue array. | |
MDValuePtr | Child (int Index) |
MDValuePtr | operator[] (const std::string ChildName) |
Access function for child values of compound items. | |
MDValuePtr | Child (const std::string ChildName) |
MDValuePtr | operator[] (const UL &Child) |
Access function for child values of compound items. | |
MDValuePtr | Child (const UL &Child) |
bool | operator== (MDValuePtr &RHS) |
Value comparison. | |
bool | operator== (MDValue &RHS) |
Value comparison. | |
MDValue & | operator= (MDValue &RHS) |
Value copy. | |
void | SetInt (Int32 Val) |
void | SetInt64 (Int64 Val) |
void | SetUInt (UInt32 Val) |
void | SetUInt64 (UInt64 Val) |
void | SetUint (UInt32 Val) |
void | SetUint64 (UInt64 Val) |
void | SetString (std::string Val) |
Int32 | GetInt (void) |
Int64 | GetInt64 (void) |
UInt32 | GetUInt (void) |
UInt64 | GetUInt64 (void) |
UInt32 | GetUint (void) |
UInt64 | GetUint64 (void) |
std::string | GetString (void) |
Int32 | GetInt (const char *ChildName, Int32 Default=0) |
Int64 | GetInt64 (const char *ChildName, Int64 Default=0) |
UInt32 | GetUInt (const char *ChildName, UInt32 Default=0) |
UInt64 | GetUInt64 (const char *ChildName, UInt64 Default=0) |
UInt32 | GetUint (const char *ChildName, UInt32 Default=0) |
UInt64 | GetUint64 (const char *ChildName, UInt64 Default=0) |
std::string | GetString (const char *ChildName, std::string Default="") |
void | SetInt (const char *ChildName, Int32 Val) |
void | SetInt64 (const char *ChildName, Int64 Val) |
void | SetUInt (const char *ChildName, UInt32 Val) |
void | SetUInt64 (const char *ChildName, UInt64 Val) |
void | SetUint (const char *ChildName, UInt32 Val) |
void | SetUint64 (const char *ChildName, UInt64 Val) |
void | SetString (const char *ChildName, std::string Val) |
Int32 | GetInt (const UL &Child, Int32 Default=0) |
Int64 | GetInt64 (const UL &Child, Int64 Default=0) |
UInt32 | GetUInt (const UL &Child, UInt32 Default=0) |
UInt64 | GetUInt64 (const UL &Child, UInt64 Default=0) |
UInt32 | GetUint (const UL &Child, UInt32 Default=0) |
UInt64 | GetUint64 (const UL &Child, UInt64 Default=0) |
std::string | GetString (const UL &Child, std::string Default="") |
void | SetInt (const UL &Child, Int32 Val) |
void | SetInt64 (const UL &Child, Int64 Val) |
void | SetUInt (const UL &Child, UInt32 Val) |
void | SetUInt64 (const UL &Child, UInt64 Val) |
void | SetUint (const UL &Child, UInt32 Val) |
void | SetUint64 (const UL &Child, UInt64 Val) |
void | SetString (const UL &Child, std::string Val) |
void | ReadValue (const char *ChildName, const DataChunk &Source) |
void | ReadValue (const char *ChildName, DataChunkPtr &Source) |
void | ReadValue (const UL &Child, const DataChunk &Source) |
void | ReadValue (const UL &Child, DataChunkPtr &Source) |
size_t | MakeSize (size_t NewSize) |
Set a variable to be a certain size in bytes. | |
size_t | ReadValue (const DataChunk &Chunk) |
size_t | ReadValue (DataChunkPtr &Chunk) |
size_t | ReadValue (const UInt8 *Buffer, size_t Size, int Count=0) |
Read value from a buffer. | |
const DataChunk & | GetData (void) |
Get a reference to the data chunk (const to prevent setting!!). | |
DataChunkPtr | PutData (void) |
Build a data chunk with all this items data (including child data). | |
void | SetData (size_t MemSize, const UInt8 *Buffer) |
Set data into the datachunk. | |
const std::string & | Name (void) const |
MDTypePtr | GetType (void) |
MDTypePtr | EffectiveType (void) |
MDTypePtr | EffectiveBase (void) |
Private Attributes | |
MDTypePtr | Type |
DataChunk | Data |
MDValue | ( | const std::string & | BaseType | ) |
MDValue named constructor.
Builds a "blank" variable of a named type
MDValue typed constructor.
Builds a "blank" variable of a specified type
~MDValue | ( | ) | [inline] |
void Init | ( | void | ) |
Second part of MDValue constructors.
Builds a "blank" variable
void AddChild | ( | MDValuePtr | Child, | |
int | Index = -1 | |||
) |
Add a child to an MDValue continer.
If the container is an array the index number of the new object can be ! specified. If the index number is specified and a child already exists ! with that number it is replaced. If the index number is specified and ! it is not the next index available, extra 'empty' objects are added to ! grow the array to the appropriate size.
void Resize | ( | UInt32 | Count | ) |
Add or Remove children from an MDValue continer to make a fixed size.
Probably only useful for resizing arrays.
MDValuePtr operator[] | ( | int | Index | ) |
MDValuePtr Child | ( | int | Index | ) | [inline] |
MDValuePtr operator[] | ( | const std::string | ChildName | ) |
Access function for child values of compound items.
DRAGONS: This doesn't work well with SmartPtrs so member function Child() is also available
MDValuePtr Child | ( | const std::string | ChildName | ) | [inline] |
MDValuePtr operator[] | ( | const UL & | Child | ) |
Access function for child values of compound items.
DRAGONS: This doesn't work well with SmartPtrs so member function Child() is also available
MDValuePtr Child | ( | const UL & | Child | ) | [inline] |
bool operator== | ( | MDValuePtr & | RHS | ) | [inline] |
Value comparison.
bool operator== | ( | MDValue & | RHS | ) | [inline] |
Value comparison.
void SetInt | ( | Int32 | Val | ) | [inline] |
void SetInt64 | ( | Int64 | Val | ) | [inline] |
void SetUInt | ( | UInt32 | Val | ) | [inline] |
void SetUInt64 | ( | UInt64 | Val | ) | [inline] |
void SetUint | ( | UInt32 | Val | ) | [inline] |
void SetUint64 | ( | UInt64 | Val | ) | [inline] |
void SetString | ( | std::string | Val | ) | [inline] |
Int32 GetInt | ( | void | ) | [inline] |
Int64 GetInt64 | ( | void | ) | [inline] |
UInt32 GetUInt | ( | void | ) | [inline] |
UInt64 GetUInt64 | ( | void | ) | [inline] |
UInt32 GetUint | ( | void | ) | [inline] |
UInt64 GetUint64 | ( | void | ) | [inline] |
std::string GetString | ( | void | ) | [inline] |
std::string GetString | ( | const char * | ChildName, | |
std::string | Default = "" | |||
) | [inline] |
void SetInt | ( | const char * | ChildName, | |
Int32 | Val | |||
) | [inline] |
void SetInt64 | ( | const char * | ChildName, | |
Int64 | Val | |||
) | [inline] |
void SetUInt | ( | const char * | ChildName, | |
UInt32 | Val | |||
) | [inline] |
void SetUInt64 | ( | const char * | ChildName, | |
UInt64 | Val | |||
) | [inline] |
void SetUint | ( | const char * | ChildName, | |
UInt32 | Val | |||
) | [inline] |
void SetUint64 | ( | const char * | ChildName, | |
UInt64 | Val | |||
) | [inline] |
void SetString | ( | const char * | ChildName, | |
std::string | Val | |||
) | [inline] |
std::string GetString | ( | const UL & | Child, | |
std::string | Default = "" | |||
) | [inline] |
void SetString | ( | const UL & | Child, | |
std::string | Val | |||
) | [inline] |
void ReadValue | ( | const char * | ChildName, | |
const DataChunk & | Source | |||
) | [inline] |
void ReadValue | ( | const char * | ChildName, | |
DataChunkPtr & | Source | |||
) | [inline] |
void ReadValue | ( | const UL & | Child, | |
DataChunkPtr & | Source | |||
) | [inline] |
size_t MakeSize | ( | size_t | NewSize | ) |
Set a variable to be a certain size in bytes.
The old data is NOT copied. This function assumes that this is a viable thing to do!
size_t ReadValue | ( | const DataChunk & | Chunk | ) | [inline] |
size_t ReadValue | ( | DataChunkPtr & | Chunk | ) | [inline] |
size_t ReadValue | ( | const UInt8 * | Buffer, | |
size_t | Size, | |||
int | Count = 0 | |||
) |
Read value from a buffer.
const DataChunk& GetData | ( | void | ) | [inline] |
Get a reference to the data chunk (const to prevent setting!!).
DataChunkPtr PutData | ( | void | ) |
Build a data chunk with all this items data (including child data).
void SetData | ( | size_t | MemSize, | |
const UInt8 * | Buffer | |||
) | [inline] |
Set data into the datachunk.
const std::string& Name | ( | void | ) | const [inline] |
MDTypePtr GetType | ( | void | ) | [inline] |
MDTypePtr EffectiveType | ( | void | ) | [inline] |
MDTypePtr EffectiveBase | ( | void | ) | [inline] |