70 bool get(
int i)
const;
91 : BitSetBase(a0,s),
a(a0),
_offset(o) {}
139 template <
class A,
class Char,
class Traits>
140 std::basic_ostream<Char,Traits>&
142 for (
int i = bs.
offset() ; i < bs.
offset()+
static_cast<int>(bs.
size()) ; i++)
void dispose(A &a)
Dispose memory for bit set.
bool get(unsigned int i) const
Access value at bit i.
unsigned int size(void) const
Return size of bitset (number of bits)
void clear(unsigned int i)
Clear bit i.
void set(unsigned int i)
Set bit i.
unsigned int next(unsigned int i) const
Return position greater or equal i of next set bit (i is allowed to be equal to size)
void resize(A &a, unsigned int n, bool setbits=false)
Resize bitset to n elememts.
Bitsets with index offset.
~BitSetOffset(void)
Destructor.
bool get(int i) const
Access value at bit i.
int next(int i) const
Return position greater or equal i of next set bit (i is allowed to be equal to size)
bool valid(int i) const
Is the bit index valid for this bitset?
int max_bit(void) const
Retrieve the maximum valid index.
void resize(A &a, unsigned int n, int offset, bool set=false)
Resize bitset to n elements with specified offset.
void set(int i)
Set bit i.
void clear(int i)
Clear bit i.
BitSetOffset(A &a, unsigned int s, int o)
Bit set with space for s bits with offset of \o.
Support algorithms and datastructures
std::basic_ostream< Char, Traits > & operator<<(std::basic_ostream< Char, Traits > &os, const BitSetOffset< A > &bs)
Gecode toplevel namespace