|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.ning.compress.lzf.ChunkEncoder
public class ChunkEncoder
Class that handles actual encoding of individual chunks. Resulting chunks can be compressed or non-compressed; compression is only used if it actually reduces chunk size (including overhead of additional header bytes)
| Constructor Summary | |
|---|---|
ChunkEncoder(int totalLength)
|
|
| Method Summary | |
|---|---|
void |
close()
Method to close once encoder is no longer in use. |
void |
encodeAndWriteChunk(byte[] data,
int offset,
int len,
OutputStream out)
Method for encoding individual chunk, writing it to given output stream. |
LZFChunk |
encodeChunk(byte[] data,
int offset,
int len)
Method for compressing (or not) individual chunks |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ChunkEncoder(int totalLength)
totalLength - Total encoded length; used for calculating size
of hash table to use| Method Detail |
|---|
public void close()
encodeChunk(byte[], int, int) will fail
public LZFChunk encodeChunk(byte[] data,
int offset,
int len)
public void encodeAndWriteChunk(byte[] data,
int offset,
int len,
OutputStream out)
throws IOException
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||