Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Classes | Public Member Functions

Map< Key, T > Class Template Reference
[Datastructures]

Map class based on the STL map (containing serveral convenience functions). More...

#include <OpenMS/DATASTRUCTURES/Map.h>

Inherits std::map< Key, T >.

List of all members.

Classes

class  IllegalKey
 Map illegal key exception. More...

Public Types

OpenMS style typedefs

typedef std::map< Key, T > Base
typedef Base::value_type ValueType
typedef Key KeyType
typedef Base::value_type * PointerType
typedef Base::iterator Iterator
typedef Base::const_iterator ConstIterator
typedef Base::reverse_iterator ReverseIterator
typedef
Base::const_reverse_iterator 
ConstReverseIterator

Public Member Functions

bool has (const Key &key) const
 Test whether the map contains the given key.
const T & operator[] (const Key &key) const
 Return a constant reference to the element whose key is key.
T & operator[] (const Key &key)
 Return a mutable reference to the element whose key is key. If an element with the key key does not exist, it is inserted.

Detailed Description

template<class Key, class T>
class OpenMS::Map< Key, T >

Map class based on the STL map (containing serveral convenience functions).


Member Typedef Documentation

typedef std::map<Key, T> Base
typedef Base::const_iterator ConstIterator
typedef Base::const_reverse_iterator ConstReverseIterator
typedef Base::iterator Iterator
typedef Key KeyType
typedef Base::value_type* PointerType
typedef Base::reverse_iterator ReverseIterator
typedef Base::value_type ValueType

Member Function Documentation

bool has ( const Key &  key  )  const [inline]

Test whether the map contains the given key.

Referenced by MzMLHandler< MapType >::writeTo(), and MzDataHandler< MapType >::writeTo().

T & operator[] ( const Key &  key  ) 

Return a mutable reference to the element whose key is key. If an element with the key key does not exist, it is inserted.

const T & operator[] ( const Key &  key  )  const

Return a constant reference to the element whose key is key.

Exceptions:
IllegalKey if the given key does not exist

OpenMS / TOPP release 1.10.0 Documentation generated on Thu Mar 7 2013 09:42:52 using doxygen 1.7.1