@UnstableApi public class DefaultHttp2FrameReader extends java.lang.Object implements Http2FrameReader, Http2FrameSizePolicy, Http2FrameReader.Configuration
Http2FrameReader that supports all frame types defined by the HTTP/2 specification.| 限定符和类型 | 类和说明 |
|---|---|
protected class |
DefaultHttp2FrameReader.HeadersBlockBuilder
Utility class to help with construction of the headers block that may potentially span
multiple frames.
|
Http2FrameReader.Configuration| 构造器和说明 |
|---|
DefaultHttp2FrameReader()
Create a new instance.
|
DefaultHttp2FrameReader(boolean validateHeaders)
Create a new instance.
|
DefaultHttp2FrameReader(Http2HeadersDecoder headersDecoder) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
close()
Closes this reader and frees any allocated resources.
|
Http2FrameReader.Configuration |
configuration()
Get the configuration related elements for this
Http2FrameReader |
Http2FrameSizePolicy |
frameSizePolicy()
Get the
Http2FrameSizePolicy for this Http2FrameReader |
Http2HeadersDecoder.Configuration |
headersConfiguration()
Get the
Http2HeadersDecoder.Configuration for this Http2FrameReader |
int |
maxFrameSize()
Gets the maximum allowed frame size.
|
void |
maxFrameSize(int max)
Sets the maximum allowed frame size.
|
void |
readFrame(ChannelHandlerContext ctx,
ByteBuf input,
Http2FrameListener listener)
Attempts to read the next frame from the input buffer.
|
public DefaultHttp2FrameReader()
Header names will be validated.
public DefaultHttp2FrameReader(boolean validateHeaders)
validateHeaders - true to validate headers. false to not validate headers.DefaultHttp2HeadersDecoder(boolean)public DefaultHttp2FrameReader(Http2HeadersDecoder headersDecoder)
public Http2HeadersDecoder.Configuration headersConfiguration()
Http2FrameReader.ConfigurationHttp2HeadersDecoder.Configuration for this Http2FrameReaderpublic Http2FrameReader.Configuration configuration()
Http2FrameReaderHttp2FrameReaderconfiguration 在接口中 Http2FrameReaderpublic Http2FrameSizePolicy frameSizePolicy()
Http2FrameReader.ConfigurationHttp2FrameSizePolicy for this Http2FrameReaderpublic void maxFrameSize(int max)
throws Http2Exception
Http2FrameSizePolicy
This value is used to represent
SETTINGS_MAX_FRAME_SIZE. This method should
only be called by Netty (not users) as a result of a receiving a SETTINGS frame.
maxFrameSize 在接口中 Http2FrameSizePolicyHttp2Exceptionpublic int maxFrameSize()
Http2FrameSizePolicy
This value is used to represent
SETTINGS_MAX_FRAME_SIZE. The initial value
defined by the RFC is unlimited but enforcing a lower limit is generally permitted.
Http2CodecUtil.DEFAULT_MAX_FRAME_SIZE can be used as a more conservative default.
maxFrameSize 在接口中 Http2FrameSizePolicypublic void close()
Http2FrameReaderclose 在接口中 Http2FrameReaderclose 在接口中 java.io.Closeableclose 在接口中 java.lang.AutoCloseablepublic void readFrame(ChannelHandlerContext ctx, ByteBuf input, Http2FrameListener listener) throws Http2Exception
Http2FrameReaderreadFrame 在接口中 Http2FrameReaderHttp2Exception