HttpRequestDecoder and HttpResponseEncoder
which enables easier server side HTTP implementation.
HttpClientCodec
| Modifier and Type | Class and Description |
|---|---|
| private class | |
| private class |
| Modifier and Type | Field and Description |
|---|---|
| private final Queue | queue
A queue that is used for correlating a request and a response. |
| Access | Constructor and Description |
|---|---|
| public | HttpServerCodec()
Creates a new instance with the default decoder options
( |
| public | HttpServerCodec(int maxInitialLineLength, int maxHeaderSize)
Creates a new instance with the specified decoder options. |
| public | HttpServerCodec(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders)
Creates a new instance with the specified decoder options. |
| public | HttpServerCodec(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize)
Creates a new instance with the specified decoder options. |
| public | HttpServerCodec(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize, boolean allowDuplicateContentLengths)
Creates a new instance with the specified decoder options. |
| Modifier and Type | Method and Description |
|---|---|
| public void | upgradeFrom(ChannelHandlerContext ctx)
Implements io. |
| queue | back to summary |
|---|---|
| private final Queue<HttpMethod> queue A queue that is used for correlating a request and a response. | |
| HttpServerCodec | back to summary |
|---|---|
| public HttpServerCodec() Creates a new instance with the default decoder options
( | |
| HttpServerCodec | back to summary |
|---|---|
| public HttpServerCodec(int maxInitialLineLength, int maxHeaderSize) Creates a new instance with the specified decoder options. | |
| HttpServerCodec | back to summary |
|---|---|
| public HttpServerCodec(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders) Creates a new instance with the specified decoder options. | |
| HttpServerCodec | back to summary |
|---|---|
| public HttpServerCodec(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize) Creates a new instance with the specified decoder options. | |
| HttpServerCodec | back to summary |
|---|---|
| public HttpServerCodec(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize, boolean allowDuplicateContentLengths) Creates a new instance with the specified decoder options. | |
| upgradeFrom | back to summary |
|---|---|
| public void upgradeFrom(ChannelHandlerContext ctx) Implements io. Upgrades to another protocol from HTTP. Removes the
| |
| Modifier and Type | Field and Description |
|---|---|
| private ChannelHandlerContext |
| Access | Constructor and Description |
|---|---|
| pack-priv | |
| pack-priv | |
| pack-priv | HttpServerRequestDecoder(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize)
|
| pack-priv | HttpServerRequestDecoder(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize, boolean allowDuplicateContentLengths)
|
| Modifier and Type | Method and Description |
|---|---|
| protected void | decode(final ChannelHandlerContext
the ctx, Buffer ChannelHandlerContext which this ByteToMessageDecoder belongs tothe buffer)Buffer from which to read dataOverrides io. Buffer to another.
|
| protected void | handlerAdded0(final ChannelHandlerContext ctx)
Overrides io. |
| context | back to summary |
|---|---|
| private ChannelHandlerContext context | |
| HttpServerRequestDecoder | back to summary |
|---|---|
| pack-priv HttpServerRequestDecoder(int maxInitialLineLength, int maxHeaderSize) | |
| HttpServerRequestDecoder | back to summary |
|---|---|
| pack-priv HttpServerRequestDecoder(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders) | |
| HttpServerRequestDecoder | back to summary |
|---|---|
| pack-priv HttpServerRequestDecoder(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize) | |
| HttpServerRequestDecoder | back to summary |
|---|---|
| pack-priv HttpServerRequestDecoder(int maxInitialLineLength, int maxHeaderSize, boolean validateHeaders, int initialBufferSize, boolean allowDuplicateContentLengths) | |
| decode | back to summary |
|---|---|
| protected void decode(final ChannelHandlerContext ctx, Buffer buffer) throws Exception Overrides io. Doc from io. Decode the from one
| |
| handlerAdded0 | back to summary |
|---|---|
| protected void handlerAdded0(final ChannelHandlerContext ctx) Overrides io.
| |
| Modifier and Type | Field and Description |
|---|---|
| private HttpMethod |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| protected boolean | isContentAlwaysEmpty(HttpResponse
the message to test msg)Overrides io. |
| protected void | sanitizeHeadersBeforeEncode(HttpResponse msg, boolean isAlwaysEmpty)
Overrides io. |
| method | back to summary |
|---|---|
| private HttpMethod method | |
| HttpServerResponseEncoder | back to summary |
|---|---|
| private HttpServerResponseEncoder() | |
| isContentAlwaysEmpty | back to summary |
|---|---|
| protected boolean isContentAlwaysEmpty(HttpResponse msg) Overrides io. Doc from io. Determine whether a message has a content or not. Some message may have headers indicating a content without having an actual content, e.g the response to an HEAD or CONNECT request.
| |
| sanitizeHeadersBeforeEncode | back to summary |
|---|---|
| protected void sanitizeHeadersBeforeEncode(HttpResponse msg, boolean isAlwaysEmpty) Overrides io. Doc from io. Allows to sanitize headers of the message before encoding these.
| |