Class DeflateInputStream
- java.lang.Object
-
- java.io.InputStream
-
- org.apache.manifoldcf.connectorcommon.common.DeflateInputStream
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
public class DeflateInputStream extends java.io.InputStreamDeflate input stream. This class takes logic from HttpComponents HttpClient 4.2.x that really should have been exposed as an independent input stream wrapper, and does it the right way. I will also open an HttpClient ticket so that this code can be pushed upstream eventually.
-
-
Constructor Summary
Constructors Constructor Description DeflateInputStream(java.io.InputStream wrapped)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intavailable()Get available.voidclose()Close.voidmark(int readLimit)Mark.booleanmarkSupported()Check if mark is supported.intread()Read a byte.intread(byte[] b)Read lots of bytes.intread(byte[] b, int off, int len)Read lots of specific bytes.voidreset()Reset.longskip(long n)Skip
-
-
-
Method Detail
-
read
public int read() throws java.io.IOExceptionRead a byte.- Specified by:
readin classjava.io.InputStream- Throws:
java.io.IOException
-
read
public int read(byte[] b) throws java.io.IOExceptionRead lots of bytes.- Overrides:
readin classjava.io.InputStream- Throws:
java.io.IOException
-
read
public int read(byte[] b, int off, int len) throws java.io.IOExceptionRead lots of specific bytes.- Overrides:
readin classjava.io.InputStream- Throws:
java.io.IOException
-
skip
public long skip(long n) throws java.io.IOExceptionSkip- Overrides:
skipin classjava.io.InputStream- Throws:
java.io.IOException
-
available
public int available() throws java.io.IOExceptionGet available.- Overrides:
availablein classjava.io.InputStream- Throws:
java.io.IOException
-
mark
public void mark(int readLimit)
Mark.- Overrides:
markin classjava.io.InputStream
-
reset
public void reset() throws java.io.IOExceptionReset.- Overrides:
resetin classjava.io.InputStream- Throws:
java.io.IOException
-
markSupported
public boolean markSupported()
Check if mark is supported.- Overrides:
markSupportedin classjava.io.InputStream
-
close
public void close() throws java.io.IOExceptionClose.- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfacejava.io.Closeable- Overrides:
closein classjava.io.InputStream- Throws:
java.io.IOException
-
-