@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.Configuration
Http2HeadersDecoder.Configuration
for this Http2FrameReader
public Http2FrameReader.Configuration configuration()
Http2FrameReader
Http2FrameReader
configuration
在接口中 Http2FrameReader
public Http2FrameSizePolicy frameSizePolicy()
Http2FrameReader.Configuration
Http2FrameSizePolicy
for this Http2FrameReader
public 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
在接口中 Http2FrameSizePolicy
Http2Exception
public 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
在接口中 Http2FrameSizePolicy
public void close()
Http2FrameReader
close
在接口中 Http2FrameReader
close
在接口中 java.io.Closeable
close
在接口中 java.lang.AutoCloseable
public void readFrame(ChannelHandlerContext ctx, ByteBuf input, Http2FrameListener listener) throws Http2Exception
Http2FrameReader
readFrame
在接口中 Http2FrameReader
Http2Exception