Useful class for representation of "sequence" of the objects through the range of valid iterators.
More...
|
| | Range_ ()=default |
| | default constructor
|
| |
| template<typename InputIterator> |
| | Range_ (InputIterator first, InputIterator last) |
| | Constructor.
|
| |
| | Range_ (const Base &base) |
| | constructor from the pair of iterators
|
| |
| | Range_ (const Container &cont) |
| | constructor from the container
|
| |
| | Range_ (iterator ibegin) |
| |
| | ~Range_ ()=default |
| |
| 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)
|
| |
| iterator | cbegin () const |
| | access to begin of the sequence (const version )
|
| |
| iterator | cend () 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)
|
| |
| template<class C, class I> |
| bool | operator< (const Range_< C, I > &right) const |
| | compare with another range
|
| |
| template<class ANOTHERCONTAINER> |
| bool | operator< (const ANOTHERCONTAINER &right) const |
| | compare with another container
|
| |
| bool | operator== (const Range_ &right) const |
| | equality with another range
|
| |
| template<class ANOTHERCONTAINER> |
| bool | operator== (const ANOTHERCONTAINER &right) const |
| | compare with another container
|
| |
| bool | operator! () const |
| | empty sequence?
|
| |
| | operator bool () const |
| | non-empty sequence?
|
| |
| | operator const Base & () const |
| | conversion operator to the std::pair
|
| |
| const Base & | base () const |
| | conversion operator to the std::pair
|
| |
template<
class CONTAINER,
class ITERATOR = typename CONTAINER::const_iterator>
class Gaudi::Range_< CONTAINER, ITERATOR >
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:
- support the concept of "CONTAINER::value_type"
- support the concept of "CONTAINER::const_iterator"
- support the concept of "CONTAINER::const_reference"
- support the concept of "CONTAINER::const_reverse_iterator"
- the iterator should be ok for "std::distance" and "std::advance"
- support for "const_iterator CONTAINER::begin () const"
- support for "const_iterator CONTAINER::end () const"
- support for "const_reverse_iterator CONTAINER::rbegin () const"
- support for "const_reverse_iterator CONTAINER::rend () const"
- Author
- Vanya Belyaev Ivan..nosp@m.Bely.nosp@m.aev@i.nosp@m.tep..nosp@m.ru
- Date
- 2002-07-12
Definition at line 81 of file Range.h.