Generated on Wed Nov 1 15:05:21 2006 for Gecode by doxygen 1.4.5

Gecode::Iter::Ranges::Minus< I > Class Template Reference
[Range iterators]

List of all members.

Detailed Description

template<class I>
class Gecode::Iter::Ranges::Minus< I >

Range iterator for pointwise minus of a range iterator.

This iterator in effect changes the order of how ranges are iterated: the first range of the input iterator defines the last range of the Minus iterator. Upon initialization all ranges of the input iterator are stored in an array which later allows iteration in inverse direction.

Requires

 #include "gecode/iter.hh" 

Definition at line 40 of file ranges-minus.icc.

Constructors and initialization

 Minus (void)
 Default constructor.
 Minus (I &i)
 Initialize with ranges from i.
void init (I &i)
 Initialize with ranges from i.

Iteration control

bool operator() (void) const
 Test whether iterator is still at a range or done.
void operator++ (void)
 Move iterator to next range (if possible).

Range access

int min (void) const
 Return smallest value of range.
int max (void) const
 Return largest value of range.
unsigned int width (void) const
 Return width of range (distance between minimum and maximum).


Constructor & Destructor Documentation

template<class I>
Gecode::Iter::Ranges::Minus< I >::Minus void   )  [inline]
 

Default constructor.

Definition at line 86 of file ranges-minus.icc.

template<class I>
Gecode::Iter::Ranges::Minus< I >::Minus I &  i  )  [inline]
 

Initialize with ranges from i.

Definition at line 104 of file ranges-minus.icc.


Member Function Documentation

template<class I>
void Gecode::Iter::Ranges::Minus< I >::init I &  i  )  [inline]
 

Initialize with ranges from i.

Definition at line 91 of file ranges-minus.icc.

template<class I>
bool Gecode::Iter::Ranges::Minus< I >::operator() void   )  const [inline]
 

Test whether iterator is still at a range or done.

Definition at line 115 of file ranges-minus.icc.

template<class I>
void Gecode::Iter::Ranges::Minus< I >::operator++ void   )  [inline]
 

Move iterator to next range (if possible).

Definition at line 110 of file ranges-minus.icc.

template<class I>
int Gecode::Iter::Ranges::Minus< I >::min void   )  const [inline]
 

Return smallest value of range.

Definition at line 121 of file ranges-minus.icc.

template<class I>
int Gecode::Iter::Ranges::Minus< I >::max void   )  const [inline]
 

Return largest value of range.

Definition at line 126 of file ranges-minus.icc.

template<class I>
unsigned int Gecode::Iter::Ranges::Minus< I >::width void   )  const [inline]
 

Return width of range (distance between minimum and maximum).

Definition at line 131 of file ranges-minus.icc.


The documentation for this class was generated from the following file: