Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

ArrayMap Class Template Reference
[Tools to Make It Easier to Make Graph Maps]

#include <lemon/bits/array_map.h>

Inherits AlterationNotifier::ObserverBase.

Inherited by DefaultMap.

Inheritance diagram for ArrayMap:

Inheritance graph
[legend]
List of all members.

Detailed Description

template<typename _Graph, typename _Item, typename _Value>
class lemon::ArrayMap< _Graph, _Item, _Value >

The ArrayMap template class is graph map structure what automatically updates the map when a key is added to or erased from the map. This map factory uses the allocators to implement the container functionality.

The template parameter is the AlterationNotifier that the maps will belong to and the Value.


Public Types

typedef _Graph Graph
 The graph type of the maps.
typedef _Item Key
 The key type of the maps.
typedef Registry::ObserverBase Parent
 The MapBase of the Map which imlements the core regisitry function.
typedef _Value Value
 The value type of the map.

Public Member Functions

 ArrayMap (const Graph &_g)
 Graph and Registry initialized map constructor.
 ArrayMap (const Graph &_g, const Value &_v)
 It constrates a map and initialize all of the the map.
 ArrayMap (const ArrayMap &copy)
 Constructor to copy a map of the same map type.
ArrayMapoperator= (const ArrayMap &copy)
 Assign operator to copy a map of the same map type.
virtual ~ArrayMap ()
 The destructor of the map.
Valueoperator[] (const Key &key)
const Valueoperator[] (const Key &key) const
void set (const Key &key, const Value &val)
void add (const Key &key)
 Add a new key to the map. It called by the map registry.
void erase (const Key &key)
 Erase a key from the map. It called by the map registry.


Member Function Documentation

Value& operator[] const Key key  )  [inline]
 

The subscript operator. The map can be subscripted by the actual keys of the graph.

const Value& operator[] const Key key  )  const [inline]
 

The const subscript operator. The map can be subscripted by the actual keys of the graph.

void set const Key key,
const Value val
[inline]
 

Setter function of the map. Equivalent with map[key] = val. This is a compatibility feature with the not dereferable maps.


The documentation for this class was generated from the following file:
Generated on Sat Aug 27 14:16:17 2005 for LEMON by  doxygen 1.4.4