edu.ksu.cis.projects.bogor.util
Class BitBuffer

java.lang.Object
  extended by edu.ksu.cis.projects.bogor.util.BitBuffer

public class BitBuffer
extends Object

Version:
CVS $Revision: 1.6 $ $Date: 2005/05/31 14:42:37 $
Author:
Robby, Matt Hoosier

Constructor Summary
BitBuffer()
           
BitBuffer(int initialCapacity)
           
 
Method Summary
 void append(BitBuffer other)
           
 void append(boolean isOne)
           
 void append(byte value)
           
 void append(byte[] value)
           
 void append(char value)
           
 void append(double value)
           
 void append(float value)
           
 void append(int value)
           
 void append(long value)
           
 void append(long value, int bitLength)
           
 void append(short value)
           
 void ensureCapacity(int additionalBits)
           
 boolean equals(Object other)
          Compare two BitBuffer instances for semantic equivalence.
 boolean get(int pos)
           
 int getLastPos()
           
 int hashCode()
           
 void set(int pos, boolean isOne)
           
 void setPos(int pos)
           
 byte[] toByteArray()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BitBuffer

public BitBuffer(int initialCapacity)

BitBuffer

public BitBuffer()
Method Detail

getLastPos

public int getLastPos()

setPos

public void setPos(int pos)

append

public void append(boolean isOne)

append

public void append(byte value)

append

public void append(char value)

append

public void append(short value)

append

public void append(int value)

append

public void append(long value)

append

public void append(long value,
                   int bitLength)

append

public void append(float value)

append

public void append(double value)

append

public void append(byte[] value)

append

public void append(BitBuffer other)

ensureCapacity

public void ensureCapacity(int additionalBits)

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object other)
Compare two BitBuffer instances for semantic equivalence. Two bitbuffers are logically equal if they store the same number of bits and for each bit offset, the contained values are identical.

Overrides:
equals in class Object

get

public boolean get(int pos)

set

public void set(int pos,
                boolean isOne)

toByteArray

public byte[] toByteArray()

toString

public String toString()
Overrides:
toString in class Object