public class LZWCompressor extends Object
Constructor and Description |
---|
LZWCompressor(ImageOutputStream out,
int codeSize,
boolean TIFF) |
Modifier and Type | Method and Description |
---|---|
void |
compress(byte[] buf,
int offset,
int length) |
void |
dump(PrintStream out) |
void |
flush()
Indicate to compressor that no more data to go so write out
any remaining buffered data.
|
public LZWCompressor(ImageOutputStream out, int codeSize, boolean TIFF) throws IOException
out
- destination for compressed datacodeSize
- the initial code size for the LZW compressorTIFF
- flag indicating that TIFF lzw fudge needs to be appliedIOException
- if underlying output stream errorpublic void compress(byte[] buf, int offset, int length) throws IOException
buf
- data to be compressed to output streamIOException
- if underlying output stream errorpublic void flush() throws IOException
IOException
- if underlying output stream errorpublic void dump(PrintStream out)
Copyright © 2015–2022 SCIFIO. All rights reserved.