|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.egothor.util.CyclicBuffer
public final class CyclicBuffer
Constructor Summary | |
---|---|
CyclicBuffer(int size)
Creates a new instance of CyclicBuffer. |
Method Summary | |
---|---|
int |
add(byte item)
Adds a byte into the buffer. |
void |
clear()
Resets this buffer. |
boolean |
compareWith(byte[] buffer)
Compares the content of this buffer with another buffer that must be long enough. |
long |
getChecksum(java.util.zip.Checksum crc)
Calculates the checksum of the stored data with a given algorithm. |
boolean |
isFull()
|
void |
writeTo(DataOutput different)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CyclicBuffer(int size)
Method Detail |
---|
public int add(byte item)
public void clear()
public boolean compareWith(byte[] buffer)
public long getChecksum(java.util.zip.Checksum crc)
public void writeTo(DataOutput different) throws java.io.IOException
java.io.IOException
public boolean isFull()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |