Class InflaterPool
- java.lang.Object
-
- org.eclipse.jetty.util.component.AbstractLifeCycle
-
- org.eclipse.jetty.util.compression.CompressionPool<java.util.zip.Inflater>
-
- org.eclipse.jetty.util.compression.InflaterPool
-
- All Implemented Interfaces:
LifeCycle
public class InflaterPool extends CompressionPool<java.util.zip.Inflater>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
AbstractLifeCycle.AbstractLifeCycleListener
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle
LifeCycle.Listener
-
-
Field Summary
-
Fields inherited from class org.eclipse.jetty.util.compression.CompressionPool
INFINITE_CAPACITY
-
-
Constructor Summary
Constructors Constructor Description InflaterPool(int capacity, boolean nowrap)Create a Pool ofInflaterinstances.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidend(java.util.zip.Inflater inflater)static InflaterPoolensurePool(Container container)protected java.util.zip.InflaternewObject()protected voidreset(java.util.zip.Inflater inflater)-
Methods inherited from class org.eclipse.jetty.util.compression.CompressionPool
acquire, doStop, release, toString
-
Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
addLifeCycleListener, doStart, getState, getState, getStopTimeout, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, setStopTimeout, start, stop
-
-
-
-
Constructor Detail
-
InflaterPool
public InflaterPool(int capacity, boolean nowrap)Create a Pool ofInflaterinstances.If given a capacity equal to zero the Inflaters will not be pooled and will be created on acquire and ended on release. If given a negative capacity equal to zero there will be no size restrictions on the InflaterPool
- Parameters:
capacity- maximum number of Inflaters which can be contained in the poolnowrap- if true then use GZIP compatible compression for all new Inflater objects
-
-
Method Detail
-
newObject
protected java.util.zip.Inflater newObject()
- Specified by:
newObjectin classCompressionPool<java.util.zip.Inflater>
-
end
protected void end(java.util.zip.Inflater inflater)
- Specified by:
endin classCompressionPool<java.util.zip.Inflater>
-
reset
protected void reset(java.util.zip.Inflater inflater)
- Specified by:
resetin classCompressionPool<java.util.zip.Inflater>
-
ensurePool
public static InflaterPool ensurePool(Container container)
-
-