Package org.eclipse.jetty.client
Class GZIPContentDecoder
- java.lang.Object
-
- org.eclipse.jetty.http.GZIPContentDecoder
-
- org.eclipse.jetty.client.GZIPContentDecoder
-
- All Implemented Interfaces:
ContentDecoder,Destroyable
public class GZIPContentDecoder extends GZIPContentDecoder implements ContentDecoder
ContentDecoderfor the "gzip" encoding.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classGZIPContentDecoder.FactorySpecializedContentDecoder.Factoryfor the "gzip" encoding.
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_BUFFER_SIZE
-
Constructor Summary
Constructors Constructor Description GZIPContentDecoder()GZIPContentDecoder(int bufferSize)GZIPContentDecoder(ByteBufferPool byteBufferPool, int bufferSize)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected booleandecodedChunk(java.nio.ByteBuffer chunk)Called when a chunk of data is inflated.-
Methods inherited from class org.eclipse.jetty.http.GZIPContentDecoder
acquire, decode, decodeChunks, destroy, isFinished, release
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.eclipse.jetty.client.ContentDecoder
decode, release
-
-
-
-
Field Detail
-
DEFAULT_BUFFER_SIZE
public static final int DEFAULT_BUFFER_SIZE
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
GZIPContentDecoder
public GZIPContentDecoder()
-
GZIPContentDecoder
public GZIPContentDecoder(int bufferSize)
-
GZIPContentDecoder
public GZIPContentDecoder(ByteBufferPool byteBufferPool, int bufferSize)
-
-
Method Detail
-
decodedChunk
protected boolean decodedChunk(java.nio.ByteBuffer chunk)
Description copied from class:GZIPContentDecoderCalled when a chunk of data is inflated.
The default implementation aggregates all the chunks into a single buffer returned from
GZIPContentDecoder.decode(ByteBuffer).Derived implementations may choose to consume inflated chunks individually and return
truefrom this method to prevent further inflation until a subsequent call toGZIPContentDecoder.decode(ByteBuffer)orGZIPContentDecoder.decodeChunks(ByteBuffer)is made.- Overrides:
decodedChunkin classGZIPContentDecoder- Parameters:
chunk- the inflated chunk of data- Returns:
- false if inflating should continue, or true if the call
to
GZIPContentDecoder.decodeChunks(ByteBuffer)orGZIPContentDecoder.decode(ByteBuffer)should return, allowing to consume the inflated chunk and apply backpressure
-
-