#include <SymTab.hpp>
Public Types | |
typedef _KeyType | KeyType |
typedef _ValueType | ValueType |
typedef std::map< KeyType, Data > | Map |
typedef std::map< KeyType, ValueType > | UserMap |
Public Member Functions | |
bool | get (const KeyType &inKey, ValueType &outValue) const throw () |
bool | set (const KeyType &inKey, const ValueType &inValue) throw () |
bool | remove (const KeyType &inKey) throw () |
void | getValues (std::vector< ValueType > &outValues) const throw () |
void | getValueMap (UserMap &outMap) const throw () |
size_t | getSize () const throw () |
void | clear () throw () |
template<typename _Action> | |
void | applyOnAll (const _Action &action) throw (Error) |
Private Attributes | |
Map | mValues |
size_t | mNextValue |
Classes | |
struct | Data |
This class acts as a symbol table to store key-value pairs
Definition at line 44 of file SymTab.hpp.
bool torc::generic::SymTab< _KeyType, _ValueType, cOverWriteExisting >::get | ( | const KeyType & | inKey, | |
ValueType & | outValue | |||
) | const throw () [inline] |
Get a value for a key
[in] | inKey | key to look for |
[out] | outValue | resultant value |
Definition at line 154 of file SymTab.hpp.
bool torc::generic::SymTab< _KeyType, _ValueType, cOverWriteExisting >::set | ( | const KeyType & | inKey, | |
const ValueType & | inValue | |||
) | throw () [inline] |
Set a value for a key. If cOverWriteExisting is true, Existing value will be replaced.
[in] | inKey | key to look for |
[in] | inValue | value to be stored |
Definition at line 169 of file SymTab.hpp.
bool torc::generic::SymTab< _KeyType, _ValueType, cOverWriteExisting >::remove | ( | const KeyType & | inKey | ) | throw () [inline] |
Remove a value for a key
[in] | inKey | key to look for |
Definition at line 200 of file SymTab.hpp.