#include <bitvector.h>

Public Member Functions | |
| template<size_t S> | |
| BitVectorPointer (BitVectorBits< S > &bits) | |
| BitVectorPointer (unsigned *bits, size_t size) | |
| BitVectorPointer () | |
| void | Reset () |
| int | Test (unsigned index) |
| void | Set (unsigned index) |
| void | Clear (unsigned index) |
| int | TestSet (unsigned index, size_t count) |
| int | TestClear (unsigned index, size_t count) |
| void | Set (unsigned index, size_t count) |
| void | Clear (unsigned index, size_t count) |
| int | Find (size_t count, unsigned state) |
Public Attributes | |
| unsigned * | Bits |
| Pointer to array where bits are stored. | |
| size_t | Size |
| Number of bits in bit-vector. | |
Object pointing to a bit-vector (array of bits).
This is the concrete class which is used to manipulation the contents of a bit-vector.
Definition at line 124 of file bitvector.h.
| BitVectorPointer::BitVectorPointer | ( | BitVectorBits< S > & | bits | ) |
Contructor taking a BitVectorBits object.
| bits | Buffer where bits are stored. |
Definition at line 133 of file bitvector.h.
| BitVectorPointer::BitVectorPointer | ( | unsigned * | bits, | |
| size_t | size | |||
| ) |
Contructor taking an arbitrary block of memory.
| bits | Add of memory block holding bits for bit-vector. | |
| size | Number of bits in bit-vector. |
Definition at line 143 of file bitvector.h.
| BitVectorPointer::BitVectorPointer | ( | ) |
Empty contructor.
Definition at line 150 of file bitvector.h.
| void BitVectorPointer::Reset | ( | ) |
Clear all bits.
Definition at line 36 of file bitvector.cpp.
| int BitVectorPointer::Test | ( | unsigned | index | ) |
Test a single bit.
| index | The bit to test. |
Definition at line 46 of file bitvector.cpp.
| void BitVectorPointer::Set | ( | unsigned | index | ) |
| void BitVectorPointer::Clear | ( | unsigned | index | ) |
Clear a single bit.
| index | The bit to clear. |
Definition at line 60 of file bitvector.cpp.
| int BitVectorPointer::TestSet | ( | unsigned | index, | |
| size_t | count | |||
| ) |
Test if a range of bits are all set.
| index | The index of the first bit to test. | |
| count | The number of bits to test. |
Definition at line 309 of file bitvector.cpp.
| int BitVectorPointer::TestClear | ( | unsigned | index, | |
| size_t | count | |||
| ) |
Test if a range of bits are all clear.
| index | The index of the first bit to test. | |
| count | The number of bits to test. |
Definition at line 344 of file bitvector.cpp.
| void BitVectorPointer::Set | ( | unsigned | index, | |
| size_t | count | |||
| ) |
Set a range of bits.
| index | The index of the first bit to set. | |
| count | The number of bits to set. |
Definition at line 377 of file bitvector.cpp.
| void BitVectorPointer::Clear | ( | unsigned | index, | |
| size_t | count | |||
| ) |
Clear a range of bits.
| index | The index of the first bit to clear. | |
| count | The number of bits to clear. |
Definition at line 412 of file bitvector.cpp.
| int BitVectorPointer::Find | ( | size_t | count, | |
| unsigned | state | |||
| ) |
Find an region of consecutive bits of the specified state.
| count | The number of required bits. | |
| state | True to find a region of set bits, false to find clear bits. |
Definition at line 450 of file bitvector.cpp.
1.6.1