Http2StreamFrame to HttpObject,
and back. It can be used as an adapter in conjunction with Http2MultiplexHandler to make http/2 connections backward-compatible with
ChannelHandlers expecting HttpObject
For simplicity, it converts to chunked encoding unless the entire stream
is a single header.
| Modifier and Type | Field and Description |
|---|---|
| private final boolean | |
| private static final AttributeKey | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | acceptInboundMessage(Object
the message msg)Overrides io. true if and only if the specified message can be decoded by this codec.
|
| private static Channel | |
| private static HttpScheme | |
| private static Attribute | |
| protected void | |
| protected void | encodeAndClose(ChannelHandlerContext
the ctx, HttpObject ChannelHandlerContext which this handler belongs tothe obj, List<Object> HttpObject message to encodethe out)List into which the encoded msg should be added
needs to do some kind of aggregationOverrides io. HttpObject to an Http2StreamFrame.
|
| private void | |
| public void | handlerAdded(final ChannelHandlerContext ctx)
Overrides default io. ChannelHandler was added to the actual context and it's ready to handle events.
|
| public boolean | isSharable()
Overrides default io. true if this handler is sharable and thus can be added
to more than one ChannelPipeline.
|
| protected boolean | |
| private FullHttpMessage | |
| private HttpMessage | |
| private Http2Headers |
| isServer | back to summary |
|---|---|
| private final boolean isServer | |
| SCHEME_ATTR_KEY | back to summary |
|---|---|
| private static final AttributeKey<HttpScheme> SCHEME_ATTR_KEY | |
| validateHeaders | back to summary |
|---|---|
| private final boolean validateHeaders | |
| Http2StreamFrameToHttpObjectCodec | back to summary |
|---|---|
| public Http2StreamFrameToHttpObjectCodec(final boolean isServer, final boolean validateHeaders) | |
| Http2StreamFrameToHttpObjectCodec | back to summary |
|---|---|
| public Http2StreamFrameToHttpObjectCodec(final boolean isServer) | |
| acceptInboundMessage | back to summary |
|---|---|
| public boolean acceptInboundMessage(Object msg) throws Exception Overrides io. Doc from io. Returns | |
| connectionChannel | back to summary |
|---|---|
| private static Channel connectionChannel(ChannelHandlerContext ctx) | |
| connectionScheme | back to summary |
|---|---|
| private static HttpScheme connectionScheme(ChannelHandlerContext ctx) | |
| connectionSchemeAttribute | back to summary |
|---|---|
| private static Attribute | |
| decodeAndClose | back to summary |
|---|---|
| protected void decodeAndClose(ChannelHandlerContext ctx, Http2StreamFrame frame) throws Exception Overrides io.
| |
| encodeAndClose | back to summary |
|---|---|
| protected void encodeAndClose(ChannelHandlerContext ctx, HttpObject obj, List<Object> out) throws Exception Overrides io. Encode from an Note 100-Continue responses that are NOT
| |
| encodeLastContent | back to summary |
|---|---|
| private void encodeLastContent(LastHttpContent<?> last, List<Object> out) | |
| handlerAdded | back to summary |
|---|---|
| public void handlerAdded(final ChannelHandlerContext ctx) throws Exception Overrides default io. Doc from io. Gets called after the
| |
| isSharable | back to summary |
|---|---|
| public boolean isSharable() Overrides default io. Doc from io. Returns
| |
| isSsl | back to summary |
|---|---|
| protected boolean isSsl(final ChannelHandlerContext ctx) | |
| newFullMessage | back to summary |
|---|---|
| private FullHttpMessage | |
| newMessage | back to summary |
|---|---|
| private HttpMessage newMessage(final int id, final Http2Headers headers) throws Http2Exception | |
| toHttp2Headers | back to summary |
|---|---|
| private Http2Headers toHttp2Headers(final ChannelHandlerContext ctx, final HttpMessage msg) throws Exception | |