VR-Forces 4.0.4 Class Documentation
Public Member Functions
DtRwKeyValueList Class Reference

Class which holds a list of string key and string value pairs. More...

Inheritance diagram for DtRwKeyValueList:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 DtRwKeyValueList ()
 default constructor
 DtRwKeyValueList (const DtString &name, DtReaderWriterRegistry *const parentRegistry=NULL)
 constructor
 DtRwKeyValueList (const DtSymbolString &name, DtReaderWriterRegistry *const parentRegistry=NULL)
virtual ~DtRwKeyValueList ()
 destructor
 DtRwKeyValueList (const DtRwKeyValueList &orig, DtReaderWriterRegistry *const parentRegistry=NULL)
 copy constructor
DtRwKeyValueListoperator= (const DtRwKeyValueList &orig)
 assignment operator
virtual void add (const DtString &key, const DtString &value)
 Adds a key value pair to the list.
virtual void remove (const DtString &key)
 Removes a key value pair from the list, based on the provided key.
virtual void clear ()
 Clears the entire list. Same as emptyList()
virtual bool contains (const DtString &key) const
virtual DtString find (const DtString &key) const
virtual std::map< DtString,
DtString
convertToMap () const
virtual void setFromMap (const std::map< DtString, DtString > sourceMap)
 Clears the contents of this list, and sets new contents from the values in the std::map.

Detailed Description

Class which holds a list of string key and string value pairs.

This class is a DtReaderWriter, and also has associated DtBufferSerialize methods available.


Constructor & Destructor Documentation

default constructor

DtRwKeyValueList::DtRwKeyValueList ( const DtString name,
DtReaderWriterRegistry *const  parentRegistry = NULL 
)

constructor

DtRwKeyValueList::DtRwKeyValueList ( const DtSymbolString name,
DtReaderWriterRegistry *const  parentRegistry = NULL 
)
virtual DtRwKeyValueList::~DtRwKeyValueList ( ) [virtual]

destructor

DtRwKeyValueList::DtRwKeyValueList ( const DtRwKeyValueList orig,
DtReaderWriterRegistry *const  parentRegistry = NULL 
)

copy constructor


Member Function Documentation

DtRwKeyValueList& DtRwKeyValueList::operator= ( const DtRwKeyValueList orig)

assignment operator

virtual void DtRwKeyValueList::add ( const DtString key,
const DtString value 
) [virtual]

Adds a key value pair to the list.

If a previous value with this key exists, it is removed.

virtual void DtRwKeyValueList::remove ( const DtString key) [virtual]

Removes a key value pair from the list, based on the provided key.

virtual void DtRwKeyValueList::clear ( ) [virtual]

Clears the entire list. Same as emptyList()

virtual bool DtRwKeyValueList::contains ( const DtString key) const [virtual]
Returns:
True if this key exists in the list.
virtual DtString DtRwKeyValueList::find ( const DtString key) const [virtual]
Returns:
The value associated with this key in the list. If this key doesn't exists, a null string is returned.
virtual std::map<DtString, DtString> DtRwKeyValueList::convertToMap ( ) const [virtual]
Returns:
The current contents of this list as a std::map.
Note:
This is returned by value, so all data is copied, and may incur processing overhead.
virtual void DtRwKeyValueList::setFromMap ( const std::map< DtString, DtString sourceMap) [virtual]

Clears the contents of this list, and sets new contents from the values in the std::map.

All values are copied from the map.


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

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)