pcce::PropertyBag Class Reference

#include <PropertyBag.h>

Inheritance diagram for pcce::PropertyBag:

pcce::Configuration pcce::GameObject

List of all members.

Public Member Functions

 PropertyBag ()
virtual ~PropertyBag ()
void AddProperty (const std::string &name)
void RemoveProperty (const std::string &name)
bool HasProperty (const std::string &name) const
unsigned int GetPropertyCount () const
Variant GetValue (const std::string &name) const
Variant GetValueDef (const std::string &name, Variant defaultValue) const
bool HasValue (const std::string &name) const
void SetValue (const std::string &name, Variant value)
void ClearValue (const std::string &name)
int GetValueAsInt (const std::string &name) const
bool GetValueAsBool (const std::string &name) const
unsigned int GetValueAsUnsignedInt (const std::string &name) const
long int GetValueAsLongInt (const std::string &name) const
unsigned long int GetValueAsUnsignedLongInt (const std::string &name) const
tReal GetValueAsReal (const std::string &name) const
char GetValueAsChar (const std::string &name) const
unsigned char GetValueAsUnsignedChar (const std::string &name) const
std::string GetValueAsString (const std::string &name) const
tPropertyBagPtr GetValueAsPropertyBagPtr (const std::string &name) const
const_iterator begin () const
const_iterator end () const

Private Types

typedef std::map< std::string,
Variant
tPropertyMap
typedef std::pair< std::string,
Variant
tPropertyMapPair

Private Attributes

tPropertyMap mPropMap

Classes

class  const_iterator


Detailed Description

Definition at line 49 of file PropertyBag.h.


Member Typedef Documentation

typedef std::map< std::string, Variant > pcce::PropertyBag::tPropertyMap [private]

Definition at line 77 of file PropertyBag.h.

typedef std::pair< std::string, Variant > pcce::PropertyBag::tPropertyMapPair [private]

Definition at line 78 of file PropertyBag.h.


Constructor & Destructor Documentation

PropertyBag::PropertyBag (  ) 

Definition at line 42 of file PropertyBag.cpp.

00042                         : mPropMap() {
00043 }

PropertyBag::~PropertyBag (  )  [virtual]

Definition at line 45 of file PropertyBag.cpp.

00045                           {
00046 }


Member Function Documentation

void pcce::PropertyBag::AddProperty ( const std::string &  name  ) 

void pcce::PropertyBag::RemoveProperty ( const std::string &  name  ) 

bool pcce::PropertyBag::HasProperty ( const std::string &  name  )  const

unsigned int PropertyBag::GetPropertyCount (  )  const

Definition at line 64 of file PropertyBag.cpp.

References mPropMap.

00064                                                  {
00065   return mPropMap.size();
00066 }

Variant pcce::PropertyBag::GetValue ( const std::string &  name  )  const

Variant pcce::PropertyBag::GetValueDef ( const std::string &  name,
Variant  defaultValue 
) const

bool pcce::PropertyBag::HasValue ( const std::string &  name  )  const

void pcce::PropertyBag::SetValue ( const std::string &  name,
Variant  value 
)

void pcce::PropertyBag::ClearValue ( const std::string &  name  ) 

int pcce::PropertyBag::GetValueAsInt ( const std::string &  name  )  const

bool pcce::PropertyBag::GetValueAsBool ( const std::string &  name  )  const

unsigned int pcce::PropertyBag::GetValueAsUnsignedInt ( const std::string &  name  )  const

long int pcce::PropertyBag::GetValueAsLongInt ( const std::string &  name  )  const

unsigned long int pcce::PropertyBag::GetValueAsUnsignedLongInt ( const std::string &  name  )  const

tReal pcce::PropertyBag::GetValueAsReal ( const std::string &  name  )  const

char pcce::PropertyBag::GetValueAsChar ( const std::string &  name  )  const

unsigned char pcce::PropertyBag::GetValueAsUnsignedChar ( const std::string &  name  )  const

std::string pcce::PropertyBag::GetValueAsString ( const std::string &  name  )  const

tPropertyBagPtr pcce::PropertyBag::GetValueAsPropertyBagPtr ( const std::string &  name  )  const

PropertyBag::const_iterator PropertyBag::begin (  )  const

Definition at line 151 of file PropertyBag.cpp.

References mPropMap.

00151                                                    {
00152   return const_iterator(mPropMap.begin());
00153 }

PropertyBag::const_iterator PropertyBag::end (  )  const

Definition at line 155 of file PropertyBag.cpp.

References mPropMap.

00155                                                  {
00156   return const_iterator(mPropMap.end());
00157 }


Member Data Documentation

Definition at line 80 of file PropertyBag.h.

Referenced by begin(), end(), and GetPropertyCount().


The documentation for this class was generated from the following files:

Generated on Thu Mar 6 11:39:28 2008 for Protocce by  doxygen 1.5.5