Generated on Tue Feb 11 2025 17:33:26 for Gecode by doxygen 1.12.0
Gecode::Iter::Ranges::Diff< I, J > Class Template Reference

Range iterator for computing set difference. More...

#include <ranges-diff.hpp>

Protected Attributes

i
 Iterator from which to subtract.
 
j
 Iterator to be subtracted.
 
- Protected Attributes inherited from Gecode::Iter::Ranges::MinMax
int mi
 Minimum of current range.
 
int ma
 Maximum of current range.
 

Constructors and initialization

 Diff (void)
 Default constructor.
 
 Diff (I &i, J &j)
 Initialize with iterator i and j.
 
void init (I &i, J &j)
 Initialize with iterator i and j.
 

Iteration control

void operator++ (void)
 Move iterator to next range (if possible)
 

Additional Inherited Members

- Public Member Functions inherited from Gecode::Iter::Ranges::MinMax
 MinMax (void)
 Default constructor.
 
 MinMax (int min, int max)
 Initialize with range min to max.
 
bool operator() (void) const
 Test whether iterator is still at a range or done.
 
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)
 
- Protected Member Functions inherited from Gecode::Iter::Ranges::MinMax
void finish (void)
 Set range such that iteration stops
 

Detailed Description

template<class I, class J>
class Gecode::Iter::Ranges::Diff< I, J >

Range iterator for computing set difference.

Definition at line 43 of file ranges-diff.hpp.

Constructor & Destructor Documentation

◆ Diff() [1/2]

template<class I , class J >
Gecode::Iter::Ranges::Diff< I, J >::Diff ( void )
inline

Default constructor.

Definition at line 109 of file ranges-diff.hpp.

◆ Diff() [2/2]

template<class I , class J >
Gecode::Iter::Ranges::Diff< I, J >::Diff ( I & i,
J & j )
inline

Initialize with iterator i and j.

Definition at line 113 of file ranges-diff.hpp.

Member Function Documentation

◆ init()

template<class I , class J >
void Gecode::Iter::Ranges::Diff< I, J >::init ( I & i,
J & j )
inline

Initialize with iterator i and j.

Definition at line 125 of file ranges-diff.hpp.

◆ operator++()

template<class I , class J >
void Gecode::Iter::Ranges::Diff< I, J >::operator++ ( void )
inline

Move iterator to next range (if possible)

Definition at line 71 of file ranges-diff.hpp.

Member Data Documentation

◆ i

template<class I , class J >
I Gecode::Iter::Ranges::Diff< I, J >::i
protected

Iterator from which to subtract.

Definition at line 46 of file ranges-diff.hpp.

◆ j

template<class I , class J >
J Gecode::Iter::Ranges::Diff< I, J >::j
protected

Iterator to be subtracted.

Definition at line 48 of file ranges-diff.hpp.


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