#include <RangeSet.h>
Public Types | |
typedef qpid::Range< T > | Range |
typedef iterator | const_iterator |
typedef Ranges::const_iterator | RangeIterator |
Public Member Functions | |
RangeSet (const Range &r) | |
RangeSet (const T &a, const T &b) | |
bool | contiguous () const |
bool | contains (const T &t) const |
bool | contains (const Range &) const |
Range | toRange () const |
bool | operator== (const RangeSet< T > &) const |
void | addRange (const Range &) |
void | addSet (const RangeSet &) |
RangeSet & | operator+= (const T &t) |
RangeSet & | operator+= (const Range &r) |
RangeSet & | operator+= (const RangeSet &s) |
void | removeRange (const Range &) |
void | removeSet (const RangeSet &) |
RangeSet & | operator-= (const T &t) |
RangeSet & | operator-= (const Range &r) |
RangeSet & | operator-= (const RangeSet &s) |
T | front () const |
T | back () const |
iterator | begin () const |
iterator | end () const |
RangeIterator | rangesBegin () const |
RangeIterator | rangesEnd () const |
size_t | rangesSize () const |
bool | empty () const |
void | clear () |
Range | rangeContaining (const T &) const |
Return the largest contiguous range containing x. | |
template<class S> | |
void | serialize (S &s) |
template<class S> | |
void | encode (S &s) const |
template<class S> | |
void | decode (S &s) |
Friends | |
template<class U> | |
std::ostream & | operator<< (std::ostream &o, const RangeSet< U > &r) |
T must be LessThanComparable and Incrementable. RangeSet only provides const iterators.
Range< T > qpid::RangeSet< T >::toRange | ( | ) | const [inline] |
Range< T > qpid::RangeSet< T >::rangeContaining | ( | const T & | t | ) | const [inline] |
Return the largest contiguous range containing x.
Returns the empty range [x,x) if x is not in the set.