openMSX
Public Types | Public Member Functions | List of all members
StringMap< T > Class Template Reference

#include <StringMap.hh>

Inheritance diagram for StringMap< T >:
Inheritance graph
[legend]
Collaboration diagram for StringMap< T >:
Collaboration graph
[legend]

Public Types

typedef const char * key_type
typedef T mapped_type
typedef StringMapEntry< T > value_type
typedef size_t size_type
typedef StringMapConstIterator< T > const_iterator
typedef StringMapIterator< T > iterator

Public Member Functions

 StringMap (unsigned initialSize=0)
 ~StringMap ()
iterator begin ()
const_iterator begin () const
iterator end ()
const_iterator end () const
iterator find (string_ref key)
const_iterator find (string_ref key) const
lookup (string_ref key) const
T & operator[] (string_ref key)
size_type count (string_ref key) const
bool insert (value_type *keyValue)
void clear ()
value_typegetOrCreateValue (string_ref key, T val=T())
void remove (value_type *keyValue)
void erase (iterator i)
bool erase (string_ref key)
- Public Member Functions inherited from StringMapImpl
unsigned getNumBuckets () const
bool empty () const
unsigned size () const

Additional Inherited Members

- Static Public Member Functions inherited from StringMapImpl
static StringMapEntryBasegetTombstoneVal ()
- Protected Member Functions inherited from StringMapImpl
 StringMapImpl (unsigned itemSize, unsigned initSize)
unsigned lookupBucketFor (string_ref key)
int findKey (string_ref key) const
void removeKey (StringMapEntryBase *V)
StringMapEntryBaseremoveKey (string_ref key)
void rehashTable ()
- Protected Attributes inherited from StringMapImpl
StringMapEntryBase ** theTable
unsigned numBuckets
unsigned numItems
unsigned numTombstones

Detailed Description

template<typename T>
class StringMap< T >

Definition at line 194 of file StringMap.hh.

Member Typedef Documentation

template<typename T>
typedef StringMapConstIterator<T> StringMap< T >::const_iterator

Definition at line 201 of file StringMap.hh.

template<typename T>
typedef StringMapIterator<T> StringMap< T >::iterator

Definition at line 202 of file StringMap.hh.

template<typename T>
typedef const char* StringMap< T >::key_type

Definition at line 197 of file StringMap.hh.

template<typename T>
typedef T StringMap< T >::mapped_type

Definition at line 198 of file StringMap.hh.

template<typename T>
typedef size_t StringMap< T >::size_type

Definition at line 200 of file StringMap.hh.

template<typename T>
typedef StringMapEntry<T> StringMap< T >::value_type

Definition at line 199 of file StringMap.hh.

Constructor & Destructor Documentation

template<typename T>
StringMap< T >::StringMap ( unsigned  initialSize = 0)
inlineexplicit

Definition at line 204 of file StringMap.hh.

template<typename T>
StringMap< T >::~StringMap ( )
inline

Definition at line 207 of file StringMap.hh.

Member Function Documentation

template<typename T>
iterator StringMap< T >::begin ( )
inline

Definition at line 212 of file StringMap.hh.

template<typename T>
const_iterator StringMap< T >::begin ( ) const
inline

Definition at line 215 of file StringMap.hh.

template<typename T>
void StringMap< T >::clear ( )
inline

Definition at line 274 of file StringMap.hh.

Referenced by StringMap< MSXMotherBoard::SharedStuff >::~StringMap().

template<typename T>
size_type StringMap< T >::count ( string_ref  key) const
inline

Definition at line 248 of file StringMap.hh.

template<typename T>
iterator StringMap< T >::end ( )
inline
template<typename T>
const_iterator StringMap< T >::end ( ) const
inline

Definition at line 221 of file StringMap.hh.

template<typename T>
void StringMap< T >::erase ( iterator  i)
inline
template<typename T>
bool StringMap< T >::erase ( string_ref  key)
inline

Definition at line 329 of file StringMap.hh.

template<typename T>
iterator StringMap< T >::find ( string_ref  key)
inline
template<typename T>
const_iterator StringMap< T >::find ( string_ref  key) const
inline

Definition at line 230 of file StringMap.hh.

template<typename T>
value_type& StringMap< T >::getOrCreateValue ( string_ref  key,
val = T() 
)
inline

Definition at line 295 of file StringMap.hh.

Referenced by StringMap< MSXMotherBoard::SharedStuff >::operator[]().

template<typename T>
bool StringMap< T >::insert ( value_type keyValue)
inline

Definition at line 255 of file StringMap.hh.

Referenced by openmsx::HelpOption::parseOption().

template<typename T>
T StringMap< T >::lookup ( string_ref  key) const
inline

Definition at line 238 of file StringMap.hh.

template<typename T>
T& StringMap< T >::operator[] ( string_ref  key)
inline

Definition at line 244 of file StringMap.hh.

template<typename T>
void StringMap< T >::remove ( value_type keyValue)
inline

Definition at line 319 of file StringMap.hh.


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