org.apache.lucene.util
public final class BitVector extends Object
Version: $Id: BitVector.java,v 1.4 2004/03/29 22:48:05 cutting Exp $
| Constructor Summary | |
|---|---|
| BitVector(int n) Constructs a vector capable of holding n bits. | |
| BitVector(Directory d, String name) Constructs a bit vector from the file name in Directory
d, as written by the {@link #write} method. | |
| Method Summary | |
|---|---|
| void | clear(int bit) Sets the value of bit to zero. |
| int | count() Returns the total number of one bits in this vector. |
| boolean | get(int bit) Returns true if bit is one and
false if it is zero. |
| void | set(int bit) Sets the value of bit to one. |
| int | size() Returns the number of bits in this vector. |
| void | write(Directory d, String name) Writes this vector to the file name in Directory
d, in a format that can be read by the constructor {@link
#BitVector(Directory, String)}. |
n bits.name in Directory
d, as written by the {@link #write} method.bit to zero.true if bit is one and
false if it is zero.bit to one.name in Directory
d, in a format that can be read by the constructor {@link
#BitVector(Directory, String)}.