#include <BitVect.h>

Public Member Functions | |
| virtual | ~BitVect ()=0 |
| virtual bool | SetBit (const unsigned int which)=0 |
| sets a particular bit and returns its original value | |
| virtual bool | UnSetBit (const unsigned int which)=0 |
| unsets a particular bit and returns its original value | |
| virtual bool | GetBit (const unsigned int which) const =0 |
| returns the value of a particular bit | |
| virtual const unsigned int | GetNumBits () const =0 |
| returns the number of bits (the length of the BitVect) | |
| virtual const unsigned int | GetNumOnBits () const =0 |
| returns the number of on bits | |
| virtual const unsigned int | GetNumOffBits () const =0 |
| returns the number of off bits | |
| virtual void | GetOnBits (IntVect &v) const =0 |
replaces the contents of v with indices of our on bits | |
| virtual void | ClearBits ()=0 |
| clears (sets to off) all of our bits | |
| void | InitFromText (const char *data, const unsigned int dataLen, bool isBase64=false, bool allowOldFormat=false) |
| initializes this BitVect from a pickle | |
| virtual std::string | ToString () const =0 |
| returns a serialized (pickled) version of this BitVect | |
| virtual bool | operator[] (const unsigned int which) const =0 |
Definition at line 20 of file BitVect.h.
| virtual BitVect::~BitVect | ( | ) | [pure virtual] |
| virtual bool BitVect::SetBit | ( | const unsigned int | which | ) | [pure virtual] |
sets a particular bit and returns its original value
Implemented in ExplicitBitVect, and SparseBitVect.
| virtual bool BitVect::UnSetBit | ( | const unsigned int | which | ) | [pure virtual] |
unsets a particular bit and returns its original value
Implemented in ExplicitBitVect, and SparseBitVect.
| virtual bool BitVect::GetBit | ( | const unsigned int | which | ) | const [pure virtual] |
| virtual const unsigned int BitVect::GetNumBits | ( | ) | const [pure virtual] |
returns the number of bits (the length of the BitVect)
Implemented in ExplicitBitVect, and SparseBitVect.
| virtual const unsigned int BitVect::GetNumOnBits | ( | ) | const [pure virtual] |
| virtual const unsigned int BitVect::GetNumOffBits | ( | ) | const [pure virtual] |
| virtual void BitVect::GetOnBits | ( | IntVect & | v | ) | const [pure virtual] |
replaces the contents of v with indices of our on bits
Implemented in ExplicitBitVect, and SparseBitVect.
| virtual void BitVect::ClearBits | ( | ) | [pure virtual] |
| void BitVect::InitFromText | ( | const char * | data, | |
| const unsigned int | dataLen, | |||
| bool | isBase64 = false, |
|||
| bool | allowOldFormat = false | |||
| ) |
initializes this BitVect from a pickle
| data | the raw pickle data | |
| dataLen | the length of data | |
| isBase64 | (optional) if this is set, data is assumed to be base64 encoded. | |
| allowOldFormat | (optional) allows a very old form of the BitVect representation to be recognized. This argument disables a large amount of error checking and it is strongly suggested that it not be used in client code. |
| virtual std::string BitVect::ToString | ( | ) | const [pure virtual] |
returns a serialized (pickled) version of this BitVect
Implemented in ExplicitBitVect, and SparseBitVect.
| virtual bool BitVect::operator[] | ( | const unsigned int | which | ) | const [pure virtual] |
Implemented in ExplicitBitVect, and SparseBitVect.
1.5.5