|
Gaudi Framework, version v23r9 |
| Home | Generated: Thu Jul 18 2013 |
Useful class for representation of "sequence" of the objects through the range of valid iterators. More...
#include <GaudiUtils/Range.h>


Public Types | |
| typedef std::pair< typename CONTAINER::const_iterator, typename CONTAINER::const_iterator > | Base |
| typedef CONTAINER | Container |
| type for actual contained iterator | |
| typedef Container::value_type | value_type |
| typedef Container::const_iterator | iterator |
| typedef Container::const_iterator | const_iterator |
| typedef Container::const_reverse_iterator | reverse_iterator |
| typedef Container::const_reverse_iterator | const_reverse_iterator |
| typedef Container::const_reference | reference |
| typedef Container::const_reference | const_reference |
| typedef std::pair< iterator, iterator > | _Base |
| internal types | |
| typedef Range_< Container > | _Self |
Public Member Functions | |||
| Range_ () | |||
| default constructor | |||
| Range_ (iterator ibegin, iterator iend) | |||
| Constructor. | |||
| Range_ (const Base &base) | |||
| constructor from the pair of iterators | |||
| Range_ (const Container &cont) | |||
| constructor from the container | |||
| Range_ (iterator ibegin) | |||
| ~Range_ () | |||
| destructor | |||
| bool | empty () const | ||
| empty sequence ? | |||
| size_t | size () const | ||
| size of the sequence (number of elements) | |||
| iterator | begin () const | ||
| access to begin of the sequence (const version ) | |||
| iterator | end () const | ||
| access to end of the sequence (const version) | |||
| reverse_iterator | rbegin () const | ||
| access to begin of the reversed sequence (const) | |||
| reverse_iterator | rend () const | ||
| access to begin of the reversed sequence (const) | |||
| const_reference | front () const | ||
| access for the first element (only for non-empty ranges!) | |||
| const_reference | back () const | ||
| access for the back element (only for non-empty ranges!) | |||
| Range_ | slice (long index1, long index2) const | ||
| get a "slice" of a range, in Python style | |||
| const_reference | operator() (const size_t index) const | ||
| non-checked access to the elements by index (valid only for non-empty sequences) | |||
| const_reference | operator[] (const long index) const | ||
| non-checked access to the elements by index (valid only for non-empty sequences) | |||
| const_reference | at (const long index) const | ||
Checked access to the elements by index (valid for all sequences)
| |||
| bool | operator< (const Range_ &right) const | ||
| compare with another range | |||
| bool | operator< (const Container &right) const | ||
| compare with the base container | |||
| bool | operator== (const Range_ &right) const | ||
| equality with another range | |||
| bool | operator== (const Container &right) const | ||
| equality with the base container | |||
| bool | operator! () const | ||
| empty sequence? | |||
| operator const Base & () const | |||
| conversion operator to the std::pair | |||
| const Base & | base () const | ||
| conversion operator to the std::pair | |||
Private Attributes | |
| Base | m_base |
| the base itself | |
Useful class for representation of "sequence" of the objects through the range of valid iterators.
The range could be created over ALL container types which supports at least bidirectional iterators.
The minimum requirements from the container type:
| typedef std::pair<iterator,iterator> Gaudi::Range_< CONTAINER >::_Base |
| typedef Range_<Container> Gaudi::Range_< CONTAINER >::_Self |
| typedef std::pair<typename CONTAINER::const_iterator, typename CONTAINER::const_iterator> Gaudi::Range_< CONTAINER >::Base |
| typedef Container::const_iterator Gaudi::Range_< CONTAINER >::const_iterator |
| typedef Container::const_reference Gaudi::Range_< CONTAINER >::const_reference |
| typedef Container::const_reverse_iterator Gaudi::Range_< CONTAINER >::const_reverse_iterator |
| typedef CONTAINER Gaudi::Range_< CONTAINER >::Container |
| typedef Container::const_iterator Gaudi::Range_< CONTAINER >::iterator |
| typedef Container::const_reference Gaudi::Range_< CONTAINER >::reference |
| typedef Container::const_reverse_iterator Gaudi::Range_< CONTAINER >::reverse_iterator |
| typedef Container::value_type Gaudi::Range_< CONTAINER >::value_type |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Checked access to the elements by index (valid for all sequences)
| GaudiException | for out-of-range access. |
| index | the index of the element to be accessed |
Definition at line 190 of file Range.h.
|
inline |
access for the back element (only for non-empty ranges!)
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
non-checked access to the elements by index (valid only for non-empty sequences)
| index | the index of the lement to be accessed |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
access to begin of the reversed sequence (const)
Definition at line 135 of file Range.h.
|
inline |
|
inline |
get a "slice" of a range, in Python style
Definition at line 147 of file Range.h.
|
private |