32 \endcode |
34 \endcode |
33 (Except matrix maps, they have two key types.) |
35 (Except matrix maps, they have two key types.) |
34 |
36 |
35 To make easy to use them - especially as template parameters - there are <i>map concepts</i> like by graph classes. |
37 To make easy to use them - especially as template parameters - there are <i>map concepts</i> like by graph classes. |
36 <ul> |
38 <ul> |
37 <li>\ref ReadMap - values can be read out with the \c operator[]. |
39 <li>\ref concepts::ReadMap "ReadMap" - values can be read out with the \c operator[]. |
38 \code value_typed_variable = map_instance[key_value]; \endcode |
40 \code value_typed_variable = map_instance[key_value]; \endcode |
39 </li> |
41 </li> |
40 <li>\ref WriteMap - values can be set with the \c set() member function. |
42 <li>\ref concepts::WriteMap "WriteMap" - values can be set with the \c set() member function. |
41 \code map_instance.set(key_value, value_typed_expression); \endcode |
43 \code map_instance.set(key_value, value_typed_expression); \endcode |
42 </li> |
44 </li> |
43 <li>\ref ReadWriteMap - it's just a shortcut to indicate that the map is both |
45 <li>\ref concepts::ReadWriteMap "ReadWriteMap" - it's just a shortcut to indicate that the map is both |
44 readable and writable. It is delivered from them. |
46 readable and writable. It is delivered from them. |
45 </li> |
47 </li> |
46 <li>\ref ReferenceMap - a subclass of ReadWriteMap. It has two additional typedefs |
48 <li>\ref concepts::ReferenceMap "ReferenceMap" - a subclass of ReadWriteMap. It has two additional typedefs |
47 <i>Reference</i> and <i>ConstReference</i> and two overloads of \c operator[] to |
49 <i>Reference</i> and <i>ConstReference</i> and two overloads of \c operator[] to |
48 providing you constant or non-constant reference to the value belonging to a key, |
50 providing you constant or non-constant reference to the value belonging to a key, |
49 so you have a direct access to the memory address where it is stored. |
51 so you have a direct access to the memory address where it is stored. |
50 </li> |
52 </li> |
51 <li>And there are the Matrix version of these maps, where the values are assigned to a pair of keys. |
53 <li>And there are the Matrix version of these maps, where the values are assigned to a pair of keys. |
52 The keys can be different types. (\ref ReadMatrixMap, \ref WriteMatrixMap, \ref ReadWriteMatrixMap, \ref ReferenceMatrixMap) |
54 The keys can be different types. (\ref concepts::ReadMatrixMap "ReadMatrixMap", |
|
55 \ref concepts::WriteMatrixMap "WriteMatrixMap", \ref concepts::ReadWriteMatrixMap "ReadWriteMatrixMap", |
|
56 \ref concepts::ReferenceMatrixMap "ReferenceMatrixMap") |
53 </li> |
57 </li> |
54 </ul> |
58 </ul> |
55 |
59 |
56 \section maps_graph Graphs' maps |
60 \section maps_graph Graphs' maps |
57 Every \ref MappableGraphComponent "mappable" graph class has two public templates: NodeMap<VALUE> and EdgeMap<VALUE> |
61 Every \ref MappableGraphComponent "mappable" graph class has two public templates: NodeMap<VALUE> and EdgeMap<VALUE> |