Class InflaterInputStreamWithStatistics
- java.lang.Object
-
- java.io.InputStream
-
- java.io.FilterInputStream
-
- java.util.zip.InflaterInputStream
-
- org.apache.commons.compress.archivers.zip.InflaterInputStreamWithStatistics
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable,InputStreamStatistics
class InflaterInputStreamWithStatistics extends java.util.zip.InflaterInputStream implements InputStreamStatistics
Helper class to provide statistics- Since:
- 1.17
-
-
Field Summary
Fields Modifier and Type Field Description private longcompressedCountprivate longuncompressedCount
-
Constructor Summary
Constructors Constructor Description InflaterInputStreamWithStatistics(java.io.InputStream in)InflaterInputStreamWithStatistics(java.io.InputStream in, java.util.zip.Inflater inf)InflaterInputStreamWithStatistics(java.io.InputStream in, java.util.zip.Inflater inf, int size)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidfill()longgetCompressedCount()longgetUncompressedCount()intread()intread(byte[] b, int off, int len)-
Methods inherited from class java.util.zip.InflaterInputStream
available, close, mark, markSupported, reset, skip
-
-
-
-
Constructor Detail
-
InflaterInputStreamWithStatistics
public InflaterInputStreamWithStatistics(java.io.InputStream in)
-
InflaterInputStreamWithStatistics
public InflaterInputStreamWithStatistics(java.io.InputStream in, java.util.zip.Inflater inf)
-
InflaterInputStreamWithStatistics
public InflaterInputStreamWithStatistics(java.io.InputStream in, java.util.zip.Inflater inf, int size)
-
-
Method Detail
-
fill
protected void fill() throws java.io.IOException- Overrides:
fillin classjava.util.zip.InflaterInputStream- Throws:
java.io.IOException
-
read
public int read() throws java.io.IOException- Overrides:
readin classjava.util.zip.InflaterInputStream- Throws:
java.io.IOException
-
read
public int read(byte[] b, int off, int len) throws java.io.IOException- Overrides:
readin classjava.util.zip.InflaterInputStream- Throws:
java.io.IOException
-
getCompressedCount
public long getCompressedCount()
- Specified by:
getCompressedCountin interfaceInputStreamStatistics- Returns:
- the amount of raw or compressed bytes read by the stream
-
getUncompressedCount
public long getUncompressedCount()
- Specified by:
getUncompressedCountin interfaceInputStreamStatistics- Returns:
- the amount of decompressed bytes returned by the stream
-
-