public class UncompressInputStream
extends java.io.FilterInputStream
| Constructor and Description |
|---|
UncompressInputStream(java.io.InputStream is) |
| Modifier and Type | Method and Description |
|---|---|
int |
available() |
static void |
main(java.lang.String[] args)
Reads a file, uncompresses it, and sends the result to stdout.
|
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) |
static long |
uncompress(java.io.InputStream in,
java.io.OutputStream out)
Read an input stream and uncompress it to an output stream.
|
static long |
uncompress(java.lang.String fileInName,
java.io.FileOutputStream out)
Read a named file and uncompress it.
|
public UncompressInputStream(java.io.InputStream is)
throws java.io.IOException
is - the input stream to decompressjava.io.IOException - if the header is malformedpublic int read()
throws java.io.IOException
read in class java.io.FilterInputStreamjava.io.IOExceptionpublic int read(byte[] buf,
int off,
int len)
throws java.io.IOException
read in class java.io.FilterInputStreamjava.io.IOExceptionpublic long skip(long num)
throws java.io.IOException
skip in class java.io.FilterInputStreamjava.io.IOExceptionpublic int available()
throws java.io.IOException
available in class java.io.FilterInputStreamjava.io.IOExceptionpublic boolean markSupported()
markSupported in class java.io.FilterInputStreampublic static long uncompress(java.lang.String fileInName,
java.io.FileOutputStream out)
throws java.io.IOException
fileInName - Name of compressed file.out - A destination for the result. It is closed after data is sent.java.io.IOException - for any errorpublic static long uncompress(java.io.InputStream in,
java.io.OutputStream out)
throws java.io.IOException
in - the incoming InputStream. It is NOT closed.out - the destination OutputStream. It is NOT closed.java.io.IOException - for any errorpublic static void main(java.lang.String[] args)
throws java.lang.Exception
args - An array with one String element, the name of the file to read.java.io.IOException - for any failurejava.lang.ExceptionCopyright © 2000-2020 BioJava. All Rights Reserved.