|
LDMX Software
|
A wrapper around a pair of iterators to simplify range-based loops. More...
#include <Range.h>
Public Member Functions | |
| Range (Iterator b, Iterator e) | |
| Range (Range &&)=default | |
| Range (const Range &)=default | |
| Range & | operator= (Range &&)=default |
| Range & | operator= (const Range &)=default |
| Iterator | begin () const |
| Iterator | end () const |
| bool | empty () const |
| std::size_t | size () const |
Private Attributes | |
| Iterator | m_begin_ |
| Iterator | m_end_ |
A wrapper around a pair of iterators to simplify range-based loops.
Some standard library algorithms return pairs of iterators to identify a sub-range. This wrapper simplifies the iteration and should be used as follows:
for (auto indx : makeRange(std::equal_range(...)) {
...
}
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
private |
|
private |