Range iterator for range lists More...
#include <ranges-rangelist.hpp>
Protected Attributes | |
const Gecode::RangeList * | c |
Current range. More... | |
Constructors and initialization | |
RangeList (void) | |
Default constructor. More... | |
RangeList (const Gecode::RangeList *s) | |
Initialize with BndSet s. More... | |
void | init (const Gecode::RangeList *s) |
Initialize with BndSet s. More... | |
Iteration control | |
bool | operator() (void) const |
Test whether iterator is still at a range or done. More... | |
void | operator++ (void) |
Move iterator to next range (if possible) More... | |
Range access | |
int | min (void) const |
Return smallest value of range. More... | |
int | max (void) const |
Return largest value of range. More... | |
unsigned int | width (void) const |
Return width of range (distance between minimum and maximum) More... | |
Range iterator for range lists
Allows to iterate the ranges of a RangeList where the ranges must be increasing and non-overlapping.
Definition at line 48 of file ranges-rangelist.hpp.
|
inline |
Default constructor.
Definition at line 83 of file ranges-rangelist.hpp.
|
inline |
Initialize with BndSet s.
Definition at line 86 of file ranges-rangelist.hpp.
|
inline |
Initialize with BndSet s.
Definition at line 89 of file ranges-rangelist.hpp.
|
inline |
Test whether iterator is still at a range or done.
Definition at line 92 of file ranges-rangelist.hpp.
|
inline |
Move iterator to next range (if possible)
Definition at line 95 of file ranges-rangelist.hpp.
|
inline |
Return smallest value of range.
Definition at line 100 of file ranges-rangelist.hpp.
|
inline |
Return largest value of range.
Definition at line 104 of file ranges-rangelist.hpp.
|
inline |
Return width of range (distance between minimum and maximum)
Definition at line 108 of file ranges-rangelist.hpp.
|
protected |
Current range.
Definition at line 51 of file ranges-rangelist.hpp.