Generated on Thu Mar 7 2013 10:22:16 for Gecode by doxygen 1.8.3.1
Gecode::Support::BitSet< A > Class Template Reference

Simple bitsets. More...

#include <bitset.hpp>

Public Member Functions

 BitSet (A &a, unsigned int s)
 Bit set with space for s bits. More...
 
 BitSet (A &a, const BitSet &bs)
 Copy bit set bs. More...
 
 ~BitSet (void)
 Destructor. More...
 
- Public Member Functions inherited from Gecode::Support::BitSetBase
 BitSetBase (void)
 Default constructor (yields empty set) More...
 
template<class A >
 BitSetBase (A &a, unsigned int s, bool set=false)
 Initialize for s bits and allocator a. More...
 
template<class A >
 BitSetBase (A &a, const BitSetBase &bs)
 Copy from bitset bs with allocator a. More...
 
template<class A >
void init (A &a, unsigned int s, bool set=false)
 Initialize for s bits and allocator a (only after default constructor) More...
 
unsigned int size (void) const
 Return size of bitset (number of bits) More...
 
bool get (unsigned int i) const
 Access value at bit i. More...
 
void set (unsigned int i)
 Set bit i. More...
 
void clear (unsigned int i)
 Clear bit i. More...
 
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) More...
 
BitSetStatus status (void) const
 Return status of bitset. More...
 
template<class A >
void resize (A &a, unsigned int n, bool set=false)
 Resize bitset to n elememts. More...
 
template<class A >
void dispose (A &a)
 Dispose memory for bit set. More...
 

Protected Attributes

A & a
 Allocator. More...
 
- Protected Attributes inherited from Gecode::Support::BitSetBase
unsigned int sz
 Size of bitset (number of bits) More...
 
BitSetDatadata
 Stored bits. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Gecode::Support::BitSetBase
bool _get (unsigned int i) const
 Access value at bit i (no index check) More...
 
void _set (unsigned int i)
 Set bit i (no index check) More...
 
- Static Protected Attributes inherited from Gecode::Support::BitSetBase
static const unsigned int bpb = BitSetData::bpb
 Bits per base. More...
 

Detailed Description

template<class A>
class Gecode::Support::BitSet< A >

Simple bitsets.

Definition at line 49 of file bitset.hpp.

Constructor & Destructor Documentation

template<class A>
Gecode::Support::BitSet< A >::BitSet ( A &  a,
unsigned int  s 
)
inline

Bit set with space for s bits.

Definition at line 64 of file bitset.hpp.

template<class A>
Gecode::Support::BitSet< A >::BitSet ( A &  a,
const BitSet< A > &  bs 
)
inline

Copy bit set bs.

Definition at line 69 of file bitset.hpp.

template<class A >
Gecode::Support::BitSet< A >::~BitSet ( void  )
inline

Destructor.

Definition at line 74 of file bitset.hpp.

Member Data Documentation

template<class A>
A& Gecode::Support::BitSet< A >::a
protected

Allocator.

Definition at line 52 of file bitset.hpp.


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