|
Oracle | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjava.io.OutputStream
com.compoze.util.XorChecksumOutputStream
public class XorChecksumOutputStream
This class is an output stream that performs a simple xor checksum of all of the data that's being written.
| Constructor Summary | |
|---|---|
XorChecksumOutputStream()
Constructor. |
|
| Method Summary | |
|---|---|
long |
getChecksum()
Get the current value of the checksum. |
static void |
main(java.lang.String[] args)
Exerciser. |
void |
write(byte[] bytes)
Write an array of bytes. |
void |
write(byte[] bytes,
int iOffset,
int iLength)
Write an array of bytes. |
void |
write(int b)
Write a single byte. |
| Methods inherited from class java.io.OutputStream |
|---|
close, flush |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XorChecksumOutputStream()
os - the underlying OutputStream| Method Detail |
|---|
public void write(int b)
write in class java.io.OutputStreamb - the byte to writepublic void write(byte[] bytes)
write in class java.io.OutputStreambytes - the array to write
public void write(byte[] bytes,
int iOffset,
int iLength)
write in class java.io.OutputStreambytes - the array to writepublic long getChecksum()
public static void main(java.lang.String[] args)
|
Oracle | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||