java.util
Class BitSet

java.lang.Object
  extended by java.util.BitSet
All Implemented Interfaces:
Cloneable

public class BitSet
extends Object
implements Cloneable

Represents a long set of bits.


Constructor Summary
BitSet()
           
BitSet(int nbits)
           
 
Method Summary
 int cardinality()
           
 void clear()
           
 void clear(int n)
           
 Object clone()
          Create a copy of this object, using a shallow copy.
 boolean equals(Object obj)
           
 void flip(int n)
           
 boolean get(int n)
           
 boolean isEmpty()
           
 int length()
           
 void set(int n)
           
 void set(int n, boolean val)
           
 int size()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BitSet

public BitSet()

BitSet

public BitSet(int nbits)
Method Detail

cardinality

public int cardinality()

clear

public void clear()

clear

public void clear(int n)

clone

public Object clone()
Description copied from class: Object
Create a copy of this object, using a shallow copy.

Overrides:
clone in class Object
Returns:
The new copy of the Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

flip

public void flip(int n)

get

public boolean get(int n)

length

public int length()

isEmpty

public boolean isEmpty()

set

public void set(int n)

set

public void set(int n,
                boolean val)

size

public int size()

toString

public String toString()
Overrides:
toString in class Object