Package net.i2p.util
Class ReusableGZIPInputStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
java.util.zip.InflaterInputStream
net.i2p.util.ResettableGZIPInputStream
net.i2p.util.ReusableGZIPInputStream
- All Implemented Interfaces:
Closeable,AutoCloseable
public class ReusableGZIPInputStream extends ResettableGZIPInputStream
Provide a cache of reusable GZIP unzipper streams.
This provides stream output only, and therefore can handle unlimited size.
-
Field Summary
-
Method Summary
Modifier and Type Method Description static ReusableGZIPInputStreamacquire()Pull a cached instancestatic voidclearCache()Clear the cache.static voidrelease(ReusableGZIPInputStream released)Release an instance back into the cache (this will reset the state)Methods inherited from class net.i2p.util.ResettableGZIPInputStream
close, destroy, getFinished, getRemaining, getTotalExpanded, getTotalRead, initialize, read, read, read, toStringMethods inherited from class java.util.zip.InflaterInputStream
available, fill, mark, markSupported, reset, skipMethods inherited from class java.io.InputStream
nullInputStream, readAllBytes, readNBytes, readNBytes, skipNBytes, transferTo
-
Method Details
-
acquire
Pull a cached instance -
release
Release an instance back into the cache (this will reset the state) -
clearCache
public static void clearCache()Clear the cache.- Since:
- 0.9.21
-