This is a const_iterator class that extends an existing const_iterator by overriding dereference. More...
#include <iterator.hpp>
Public Types | |
typedef Container::const_iterator | base_iter_type |
typedef const Value | value_type |
typedef value_type * | pointer |
typedef value_type & | reference |
typedef base_iter_type::difference_type | difference_type |
typedef base_iter_type::iterator_category | iterator_category |
Private Attributes | |
base_iter_type | iter_ |
The underlying base iterator. More... | |
This is a const_iterator class that extends an existing const_iterator by overriding dereference.
Access to the underlying iterator is controlled, promoting a black-box approach.
The expected use of this class is as a typedef. If used in conjunction with a typedef of iterator_extend (with the same template parameters), you get conversion from your regular iterator.
Value = Intended value_type, minus "const". Container = The container whose const_iterator is being extended. Deref = A class whose member static const Value& eval(const Container::const_iterator &) can be used for dereferencing. (This same class can be used for iterator_extend.) Key = A class that unlocks the underlying const_iterator. (This way the underlying const_iterator is not exposed to everyone.) If Key is accessible, then the underlying const_iterator can be obtained via get(const Key &).
Definition at line 27 of file iterator.hpp.
typedef Container::const_iterator util::const_iterator_extend< Value, Container, Deref, Key >::base_iter_type |
Definition at line 128 of file iterator.hpp.
typedef base_iter_type::difference_type util::const_iterator_extend< Value, Container, Deref, Key >::difference_type |
Definition at line 134 of file iterator.hpp.
typedef base_iter_type::iterator_category util::const_iterator_extend< Value, Container, Deref, Key >::iterator_category |
Definition at line 135 of file iterator.hpp.
typedef value_type* util::const_iterator_extend< Value, Container, Deref, Key >::pointer |
Definition at line 132 of file iterator.hpp.
typedef value_type& util::const_iterator_extend< Value, Container, Deref, Key >::reference |
Definition at line 133 of file iterator.hpp.
typedef const Value util::const_iterator_extend< Value, Container, Deref, Key >::value_type |
Definition at line 131 of file iterator.hpp.
|
inline |
Default constructor.
Definition at line 138 of file iterator.hpp.
Referenced by util::const_iterator_extend< Value, Container, Deref, Key >::operator+(), util::const_iterator_extend< Value, Container, Deref, Key >::operator++(), util::const_iterator_extend< Value, Container, Deref, Key >::operator-(), and util::const_iterator_extend< Value, Container, Deref, Key >::operator--().
|
inlineexplicit |
Initialized constructor.
Definition at line 140 of file iterator.hpp.
|
inline |
Conversion from iterator_extend (same parameters).
Definition at line 142 of file iterator.hpp.
|
inline |
Definition at line 173 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 148 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 156 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 167 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::const_iterator_extend(), and util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 160 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 162 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::const_iterator_extend(), and util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 165 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 168 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::const_iterator_extend(), and util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 169 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 161 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 163 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::const_iterator_extend(), and util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 166 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 157 of file iterator.hpp.
|
inline |
Definition at line 150 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 152 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 147 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 151 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 153 of file iterator.hpp.
References util::const_iterator_extend< Value, Container, Deref, Key >::iter_.
|
inline |
Definition at line 170 of file iterator.hpp.
|
private |
The underlying base iterator.
Definition at line 177 of file iterator.hpp.
Referenced by util::const_iterator_extend< Value, Container, Deref, Key >::get(), util::const_iterator_extend< Value, Container, Deref, Key >::operator!=(), util::const_iterator_extend< Value, Container, Deref, Key >::operator*(), util::const_iterator_extend< Value, Container, Deref, Key >::operator+(), util::const_iterator_extend< Value, Container, Deref, Key >::operator++(), util::const_iterator_extend< Value, Container, Deref, Key >::operator+=(), util::const_iterator_extend< Value, Container, Deref, Key >::operator-(), util::const_iterator_extend< Value, Container, Deref, Key >::operator--(), util::const_iterator_extend< Value, Container, Deref, Key >::operator-=(), util::const_iterator_extend< Value, Container, Deref, Key >::operator<(), util::const_iterator_extend< Value, Container, Deref, Key >::operator<=(), util::const_iterator_extend< Value, Container, Deref, Key >::operator==(), util::const_iterator_extend< Value, Container, Deref, Key >::operator>(), and util::const_iterator_extend< Value, Container, Deref, Key >::operator>=().