Interface Http2ConnectionDecoder
- All Superinterfaces:
AutoCloseable, Closeable
- All Known Implementing Classes:
DecoratingHttp2ConnectionDecoder, DefaultHttp2ConnectionDecoder
Handler for inbound traffic on behalf of
Http2ConnectionHandler. Performs basic protocol
conformance on inbound frames before calling the delegate Http2FrameListener for
application-specific processing. Note that frames of an unknown type (i.e. HTTP/2 extensions)
will skip all protocol checks and be given directly to the listener for processing.-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()Provides direct access to the underlying connection.voiddecodeFrame(ChannelHandlerContext ctx, ByteBuf in, List<Object> out) Called by theHttp2ConnectionHandlerto decode the next frame from the input buffer.Provides the local flow controller for managing inbound traffic.Get theHttp2FrameListenerwhich will be notified when frames are decoded.voidframeListener(Http2FrameListener listener) Set theHttp2FrameListenerwhich will be notified when frames are decoded.voidlifecycleManager(Http2LifecycleManager lifecycleManager) Sets the lifecycle manager.Gets the local settings for this endpoint of the HTTP/2 connection.booleanIndicates whether or not the first initialSETTINGSframe was received from the remote endpoint.
-
Method Details
-
lifecycleManager
Sets the lifecycle manager. Must be called as part of initialization before the decoder is used. -
connection
Http2Connection connection()Provides direct access to the underlying connection. -
flowController
Http2LocalFlowController flowController()Provides the local flow controller for managing inbound traffic. -
frameListener
Set theHttp2FrameListenerwhich will be notified when frames are decoded.This must be set before frames are decoded.
-
frameListener
Http2FrameListener frameListener()Get theHttp2FrameListenerwhich will be notified when frames are decoded. -
decodeFrame
Called by theHttp2ConnectionHandlerto decode the next frame from the input buffer.- Throws:
Http2Exception
-
localSettings
Http2Settings localSettings()Gets the local settings for this endpoint of the HTTP/2 connection. -
prefaceReceived
boolean prefaceReceived()Indicates whether or not the first initialSETTINGSframe was received from the remote endpoint. -
close
void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-