represents a "Range" w/ notion of ordering. A range is defined by a pair of "start" and "end" values. This is stored in std::pair
attribute util::Range::_window. This attribute is protected so that the start/end cannot
be changed w/o a check that start is always less than end. Note the specialization
requires a template class T to have less operator implemented.
More...
#include <Range.h>
Public Member Functions | |
Range (const T &start, const T &end) | |
Enforced ctor. start must be less than end. More... | |
~Range () | |
Default dtor. More... | |
const T & | Start () const |
"start" accessor More... | |
const T & | End () const |
"end" accessor More... | |
void | Set (const T &s, const T &e) |
Setter. More... | |
bool | operator< (const Range &rhs) const |
bool | operator> (const Range &rhs) const |
bool | operator== (const Range &rhs) const |
bool | operator!= (const Range &rhs) const |
bool | operator< (const T &rhs) const |
bool | operator> (const T &rhs) const |
void | Merge (const Range &a) |
Merge two util::Range into 1. More... | |
Protected Attributes | |
std::pair< T, T > | _window |
Protected to avoid user's illegal modification on first/second (sorry users!) More... | |
Private Member Functions | |
Range () | |
Default ctor is hidden. More... | |
Friends | |
class | UniqueRangeSet< T > |
represents a "Range" w/ notion of ordering. A range is defined by a pair of "start" and "end" values. This is stored in std::pair
attribute util::Range::_window. This attribute is protected so that the start/end cannot
be changed w/o a check that start is always less than end. Note the specialization
requires a template class T to have less operator implemented.
|
inlineprivate |
|
inline |
Enforced ctor. start must be less than end.
Definition at line 44 of file Range.h.
|
inline |
|
inline |
"end" accessor
Definition at line 55 of file Range.h.
|
inline |
Merge two util::Range into 1.
Definition at line 85 of file Range.h.
|
inline |
|
inline |
Definition at line 67 of file Range.h.
|
inline |
Definition at line 79 of file Range.h.
|
inline |
Definition at line 71 of file Range.h.
|
inline |
Definition at line 69 of file Range.h.
|
inline |
Definition at line 81 of file Range.h.
|
inline |
Setter.
Definition at line 57 of file Range.h.
|
inline |
"start" accessor
Definition at line 53 of file Range.h.
|
friend |
|
protected |