Interface HttpChunk
-
- All Known Subinterfaces:
HttpChunkTrailer
- All Known Implementing Classes:
DefaultHttpChunk
,DefaultHttpChunkTrailer
public interface HttpChunk
An HTTP chunk which is used for HTTP chunked transfer-encoding.HttpMessageDecoder
generatesHttpChunk
afterHttpMessage
when the content is large or the encoding of the content is 'chunked. If you prefer not to receiveHttpChunk
in your handler, pleaseHttpChunkAggregator
afterHttpMessageDecoder
in theChannelPipeline
.
-
-
Field Summary
Fields Modifier and Type Field Description static HttpChunkTrailer
LAST_CHUNK
The 'end of content' marker in chunked encoding.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ChannelBuffer
getContent()
Returns the content of this chunk.boolean
isLast()
Returnstrue
if and only if this chunk is the 'end of content' marker.void
setContent(ChannelBuffer content)
Sets the content of this chunk.
-
-
-
Field Detail
-
LAST_CHUNK
static final HttpChunkTrailer LAST_CHUNK
The 'end of content' marker in chunked encoding.
-
-
Method Detail
-
isLast
boolean isLast()
Returnstrue
if and only if this chunk is the 'end of content' marker.
-
getContent
ChannelBuffer getContent()
Returns the content of this chunk. If this is the 'end of content' marker,ChannelBuffers.EMPTY_BUFFER
will be returned.
-
setContent
void setContent(ChannelBuffer content)
Sets the content of this chunk. If an empty buffer is specified, this chunk becomes the 'end of content' marker.
-
-