Generated on Thu Mar 22 10:39:59 2012 for Gecode by doxygen 1.6.3

Gecode::Iter::Values::Array Class Reference
[Value iterators]

Value iterator for array of integers More...

#include <values-array.hpp>

List of all members.

Protected Attributes

int * v
 Array for values.
int c
 Current value.
int n
 Number of ranges in array.

Constructors and initialization



 Array (void)
 Default constructor.
 Array (int *v, int n)
 Initialize with n values from v.
void init (int *v, int n)
 Initialize with n ranges from v.

Iteration control



bool operator() (void) const
 Test whether iterator is still at a value or done.
void operator++ (void)
 Move iterator to next value (if possible).
void reset (void)
 Reset iterator to start from beginning.

Value access



int val (void) const
 Return current value.

Detailed Description

Value iterator for array of integers

Allows to iterate the integers as defined by an array where the values in the array must be sorted in increasing order. The integers can be iterated several times provided the iterator is reset by the reset member function.

Definition at line 50 of file values-array.hpp.


Constructor & Destructor Documentation

Gecode::Iter::Values::Array::Array ( void   )  [inline]

Default constructor.

Definition at line 88 of file values-array.hpp.

Gecode::Iter::Values::Array::Array ( int *  v,
int  n 
) [inline]

Initialize with n values from v.

Definition at line 91 of file values-array.hpp.


Member Function Documentation

void Gecode::Iter::Values::Array::init ( int *  v,
int  n 
) [inline]

Initialize with n ranges from v.

Definition at line 95 of file values-array.hpp.

bool Gecode::Iter::Values::Array::operator() ( void   )  const [inline]

Test whether iterator is still at a value or done.

Definition at line 104 of file values-array.hpp.

void Gecode::Iter::Values::Array::operator++ ( void   )  [inline]

Move iterator to next value (if possible).

Definition at line 100 of file values-array.hpp.

void Gecode::Iter::Values::Array::reset ( void   )  [inline]

Reset iterator to start from beginning.

Definition at line 108 of file values-array.hpp.

int Gecode::Iter::Values::Array::val ( void   )  const [inline]

Return current value.

Definition at line 113 of file values-array.hpp.


Member Data Documentation

Array for values.

Definition at line 53 of file values-array.hpp.

Current value.

Definition at line 55 of file values-array.hpp.

Number of ranges in array.

Definition at line 57 of file values-array.hpp.


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