Package uk.ac.starlink.util
Class UncompressInputStream
- java.lang.Object
-
- java.io.InputStream
-
- java.io.FilterInputStream
-
- uk.ac.starlink.util.UncompressInputStream
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
public class UncompressInputStream extends java.io.FilterInputStream
This class decompresses an input stream containing data compressed with the unix "compress" utility (LZC, a LZW variant). This code is based heavily on the unlzw.c code in gzip-1.2.4 (written by Peter Jannesen) and the original compress code.- Version:
- 0.3-3 06/05/2001
- Author:
- Ronald Tschalär, Unidata Program Center
-
-
Constructor Summary
Constructors Constructor Description UncompressInputStream(java.io.InputStream is)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
available()
static void
main(java.lang.String[] args)
boolean
markSupported()
This stream does not support mark/reset on the stream.int
read()
int
read(byte[] buf, int off, int len)
long
skip(long num)
-
-
-
Method Detail
-
read
public int read() throws java.io.IOException
- Overrides:
read
in classjava.io.FilterInputStream
- Throws:
java.io.IOException
-
read
public int read(byte[] buf, int off, int len) throws java.io.IOException
- Overrides:
read
in classjava.io.FilterInputStream
- Throws:
java.io.IOException
-
skip
public long skip(long num) throws java.io.IOException
- Overrides:
skip
in classjava.io.FilterInputStream
- Throws:
java.io.IOException
-
available
public int available() throws java.io.IOException
- Overrides:
available
in classjava.io.FilterInputStream
- Throws:
java.io.IOException
-
markSupported
public boolean markSupported()
This stream does not support mark/reset on the stream.- Overrides:
markSupported
in classjava.io.FilterInputStream
- Returns:
- false
-
main
public static void main(java.lang.String[] args) throws java.lang.Exception
- Throws:
java.lang.Exception
-
-