Sets of integers.
More...
#include <gecode/set/var-imp.hpp>
|
| unsigned int | _size |
| | The size of this set.
|
| unsigned int | _card |
| | The cardinality this set represents.
|
|
| template<class I> |
| bool | overwrite (Space &home, I &i) |
| | Overwrite the ranges with those represented by i.
|
| RangeList * | ranges (void) const |
| | Return range list for iteration.
|
|
| | BndSet (void) |
| | Default constructor. Creates an empty set.
|
| | BndSet (Space &home, int i, int j) |
| | Initialize as the set \( \{i,\dots,j\}\).
|
| | BndSet (Space &home, const IntSet &s) |
| | Initialize as the set represented by s.
|
|
| int | min (void) const |
| | Return smallest element.
|
| int | max (void) const |
| | Return greatest element.
|
| int | minN (unsigned int n) const |
| | Return n -th smallest element.
|
| unsigned int | size (void) const |
| | Return size.
|
| unsigned int | card (void) const |
| | Return cardinality.
|
| void | card (unsigned int c) |
| | Set cardinality.
|
|
| bool | empty (void) const |
| | Test whether this set is empty.
|
| bool | in (int i) const |
| | Test whether i is an element of this set.
|
|
| void | update (Space &home, BndSet &x) |
| | Update this set to be a clone of set x.
|
| bool | isConsistent (void) const |
| | Check whether internal invariants hold.
|
Sets of integers.
Definition at line 89 of file var-imp.hpp.
◆ BndSet() [1/3]
| Gecode::Set::BndSet::BndSet |
( |
void | | ) |
|
|
inline |
Default constructor. Creates an empty set.
Definition at line 46 of file integerset.hpp.
◆ BndSet() [2/3]
| Gecode::Set::BndSet::BndSet |
( |
Space & | home, |
|
|
int | i, |
|
|
int | j ) |
|
inline |
Initialize as the set \( \{i,\dots,j\}\).
Definition at line 76 of file integerset.hpp.
◆ BndSet() [3/3]
| Gecode::Set::BndSet::BndSet |
( |
Space & | home, |
|
|
const IntSet & | s ) |
Initialize as the set represented by s.
◆ fst() [1/2]
| void Gecode::Set::BndSet::fst |
( |
RangeList * | r | ) |
|
|
inlineprotected |
◆ lst() [1/2]
| void Gecode::Set::BndSet::lst |
( |
RangeList * | r | ) |
|
|
inlineprotected |
◆ fst() [2/2]
| RangeList * Gecode::Set::BndSet::fst |
( |
void | | ) |
const |
|
inlineprotected |
◆ lst() [2/2]
| RangeList * Gecode::Set::BndSet::lst |
( |
void | | ) |
const |
|
inlineprotected |
◆ dispose()
| void Gecode::Set::BndSet::dispose |
( |
Space & | home | ) |
|
|
inline |
◆ min()
| int Gecode::Set::BndSet::min |
( |
void | | ) |
const |
|
inline |
◆ max()
| int Gecode::Set::BndSet::max |
( |
void | | ) |
const |
|
inline |
◆ minN()
| int Gecode::Set::BndSet::minN |
( |
unsigned int | n | ) |
const |
|
inline |
◆ size()
| unsigned int Gecode::Set::BndSet::size |
( |
void | | ) |
const |
|
inline |
◆ card() [1/2]
| unsigned int Gecode::Set::BndSet::card |
( |
void | | ) |
const |
|
inline |
◆ card() [2/2]
| void Gecode::Set::BndSet::card |
( |
unsigned int | c | ) |
|
|
inline |
◆ empty()
| bool Gecode::Set::BndSet::empty |
( |
void | | ) |
const |
|
inline |
◆ in()
| bool Gecode::Set::BndSet::in |
( |
int | i | ) |
const |
|
inline |
◆ become()
| void Gecode::Set::BndSet::become |
( |
Space & | home, |
|
|
const BndSet & | s ) |
|
inline |
◆ ranges()
| RangeList * Gecode::Set::BndSet::ranges |
( |
void | | ) |
const |
|
inline |
◆ overwrite()
template<class I>
| bool Gecode::Set::BndSet::overwrite |
( |
Space & | home, |
|
|
I & | i ) |
|
inlineprotected |
Overwrite the ranges with those represented by i.
Definition at line 171 of file integerset.hpp.
◆ update()
| void Gecode::Set::BndSet::update |
( |
Space & | home, |
|
|
BndSet & | x ) |
|
inline |
Update this set to be a clone of set x.
Definition at line 140 of file integerset.hpp.
◆ isConsistent()
| bool Gecode::Set::BndSet::isConsistent |
( |
void | | ) |
const |
Check whether internal invariants hold.
◆ _size
| unsigned int Gecode::Set::BndSet::_size |
|
protected |
◆ _card
| unsigned int Gecode::Set::BndSet::_card |
|
protected |
The cardinality this set represents.
Definition at line 97 of file var-imp.hpp.
◆ MAX_OF_EMPTY
| const int Gecode::Set::BndSet::MAX_OF_EMPTY = Limits::min-1 |
|
static |
Returned by empty sets when asked for their maximum element.
Definition at line 110 of file var-imp.hpp.
◆ MIN_OF_EMPTY
| const int Gecode::Set::BndSet::MIN_OF_EMPTY = Limits::max+1 |
|
static |
Returned by empty sets when asked for their minimum element.
Definition at line 112 of file var-imp.hpp.
The documentation for this class was generated from the following files: