Package com.sun.media.imageioimpl.common
Class LZWCompressor
- java.lang.Object
-
- com.sun.media.imageioimpl.common.LZWCompressor
-
public class LZWCompressor extends java.lang.ObjectModified from original LZWCompressor to change interface to passing a buffer of data to be compressed.
-
-
Constructor Summary
Constructors Constructor Description LZWCompressor(javax.imageio.stream.ImageOutputStream out, int codeSize, boolean TIFF)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcompress(byte[] buf, int offset, int length)voiddump(java.io.PrintStream out)voidflush()Indicate to compressor that no more data to go so write out any remaining buffered data.
-
-
-
Constructor Detail
-
LZWCompressor
public LZWCompressor(javax.imageio.stream.ImageOutputStream out, int codeSize, boolean TIFF) throws java.io.IOException- Parameters:
out- destination for compressed datacodeSize- the initial code size for the LZW compressorTIFF- flag indicating that TIFF lzw fudge needs to be applied- Throws:
java.io.IOException- if underlying output stream error
-
-
Method Detail
-
compress
public void compress(byte[] buf, int offset, int length) throws java.io.IOException- Parameters:
buf- data to be compressed to output stream- Throws:
java.io.IOException- if underlying output stream error
-
flush
public void flush() throws java.io.IOExceptionIndicate to compressor that no more data to go so write out any remaining buffered data.- Throws:
java.io.IOException- if underlying output stream error
-
dump
public void dump(java.io.PrintStream out)
-
-