|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.io.InputStream
java.io.FilterInputStream
java.util.zip.InflaterInputStream
net.i2p.util.ResettableGZIPInputStream
public class ResettableGZIPInputStream
GZIP implementation per RFC 1952, reusing java's standard CRC32 and Inflater and InflaterInputStream implementations. The main difference is that this implementation allows its state to be reset to initial values, and hence reused, while the standard GZIPInputStream reads the GZIP header from the stream on instantiation.
Field Summary |
---|
Fields inherited from class java.util.zip.InflaterInputStream |
---|
buf, inf, len |
Fields inherited from class java.io.FilterInputStream |
---|
in |
Constructor Summary | |
---|---|
ResettableGZIPInputStream()
Build a new GZIP stream without a bound compressed stream. |
|
ResettableGZIPInputStream(InputStream compressedStream)
Warning - blocking! |
Method Summary | |
---|---|
boolean |
getFinished()
Moved from i2ptunnel HTTPResponseOutputStream.InternalGZIPInputStream |
long |
getRemaining()
Moved from i2ptunnel HTTPResponseOutputStream.InternalGZIPInputStream |
long |
getTotalExpanded()
Moved from i2ptunnel HTTPResponseOutputStream.InternalGZIPInputStream |
long |
getTotalRead()
Moved from i2ptunnel HTTPResponseOutputStream.InternalGZIPInputStream |
void |
initialize(InputStream compressedStream)
Blocking call to initialize this stream with the data from the given compressed stream. |
int |
read()
|
int |
read(byte[] buf)
|
int |
read(byte[] buf,
int off,
int len)
|
String |
toString()
Moved from i2ptunnel HTTPResponseOutputStream.InternalGZIPInputStream |
Methods inherited from class java.util.zip.InflaterInputStream |
---|
available, close, fill, mark, markSupported, reset, skip |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public ResettableGZIPInputStream()
public ResettableGZIPInputStream(InputStream compressedStream) throws IOException
IOException
Method Detail |
---|
public void initialize(InputStream compressedStream) throws IOException
IOException
public int read() throws IOException
read
in class InflaterInputStream
IOException
public int read(byte[] buf) throws IOException
read
in class FilterInputStream
IOException
public int read(byte[] buf, int off, int len) throws IOException
read
in class InflaterInputStream
IOException
public long getTotalRead()
public long getTotalExpanded()
public long getRemaining()
public boolean getFinished()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |