@UnstableApi public final class HttpToHttp2ConnectionHandlerBuilder extends AbstractHttp2ConnectionHandlerBuilder<HttpToHttp2ConnectionHandler,HttpToHttp2ConnectionHandlerBuilder>
HttpToHttp2ConnectionHandler
对象的生成器。
Constructor and Description |
---|
HttpToHttp2ConnectionHandlerBuilder() |
connection, decoder, encoder, encoderEnforceMaxConcurrentStreams, encoderIgnoreMaxHeaderListSize, frameListener, frameLogger, gracefulShutdownTimeoutMillis, headerSensitivityDetector, initialSettings, isServer, isValidateHeaders, maxReservedStreams, maxReservedStreams, self
public HttpToHttp2ConnectionHandlerBuilder validateHeaders(boolean validateHeaders)
public HttpToHttp2ConnectionHandlerBuilder initialSettings(Http2Settings settings)
Http2Settings
设置为用于初始连接设置交换。
public HttpToHttp2ConnectionHandlerBuilder frameListener(Http2FrameListener frameListener)
null
该监听器才会被设置。
public HttpToHttp2ConnectionHandlerBuilder gracefulShutdownTimeoutMillis(long gracefulShutdownTimeoutMillis)
Http2Connection
的正常关闭超时。
public HttpToHttp2ConnectionHandlerBuilder server(boolean isServer)
AbstractHttp2ConnectionHandlerBuilder.build()
将创建一个Http2Connection
服务器模式( true
)或客户端模式( false
)。
public HttpToHttp2ConnectionHandlerBuilder connection(Http2Connection connection)
Http2Connection
。
public HttpToHttp2ConnectionHandlerBuilder codec(Http2ConnectionDecoder decoder, Http2ConnectionEncoder encoder)
public HttpToHttp2ConnectionHandlerBuilder frameLogger(Http2FrameLogger frameLogger)
public HttpToHttp2ConnectionHandlerBuilder encoderEnforceMaxConcurrentStreams(boolean encoderEnforceMaxConcurrentStreams)
public HttpToHttp2ConnectionHandlerBuilder headerSensitivityDetector(Http2HeadersEncoder.SensitivityDetector headerSensitivityDetector)
public HttpToHttp2ConnectionHandlerBuilder initialHuffmanDecodeCapacity(int initialHuffmanDecodeCapacity)
initialHuffmanDecodeCapacity
在课堂上
AbstractHttp2ConnectionHandlerBuilder<HttpToHttp2ConnectionHandler,HttpToHttp2ConnectionHandlerBuilder>
initialHuffmanDecodeCapacity
- 在HPACK huffman解码期间使用的中间缓冲区的初始大小。
public HttpToHttp2ConnectionHandler build()
Http2ConnectionHandler
。
protected HttpToHttp2ConnectionHandler build(Http2ConnectionDecoder decoder, Http2ConnectionEncoder encoder, Http2Settings initialSettings)
Http2ConnectionHandler
或其子类型实例。
此方法的返回将受到以下限制:
build
in class
AbstractHttp2ConnectionHandlerBuilder<HttpToHttp2ConnectionHandler,HttpToHttp2ConnectionHandlerBuilder>
Copyright © 2008–2018 The Netty Project. All rights reserved.