public final class DeflatingAsyncEntityProducer extends Object implements AsyncEntityProducer
AsyncEntityProducer that streams the output of another producer
through the raw DEFLATE compression algorithm.
The delegate’s bytes are read in small chunks, compressed with
Deflater and written immediately to the HTTP I/O
layer. Memory use is therefore bounded even for very large request
entities.
| Constructor and Description |
|---|
DeflatingAsyncEntityProducer(AsyncEntityProducer delegate) |
| Modifier and Type | Method and Description |
|---|---|
int |
available() |
void |
failed(Exception cause) |
String |
getContentEncoding() |
long |
getContentLength() |
String |
getContentType() |
Set<String> |
getTrailerNames() |
boolean |
isChunked() |
boolean |
isRepeatable() |
void |
produce(DataStreamChannel channel) |
void |
releaseResources() |
public DeflatingAsyncEntityProducer(AsyncEntityProducer delegate)
public boolean isRepeatable()
isRepeatable in interface AsyncEntityProducerpublic long getContentLength()
getContentLength in interface EntityDetailspublic String getContentType()
getContentType in interface EntityDetailspublic String getContentEncoding()
getContentEncoding in interface EntityDetailspublic boolean isChunked()
isChunked in interface EntityDetailspublic Set<String> getTrailerNames()
getTrailerNames in interface EntityDetailspublic int available()
available in interface AsyncDataProducerpublic void produce(DataStreamChannel channel) throws IOException
produce in interface AsyncDataProducerIOExceptionpublic void failed(Exception cause)
failed in interface AsyncEntityProducerpublic void releaseResources()
releaseResources in interface ResourceHolderCopyright © 1999–2021 The Apache Software Foundation. All rights reserved.