Package io.netty.handler.codec.http2
Class AbstractHttp2StreamChannel.Http2StreamChannelConfig
- java.lang.Object
-
- io.netty.channel.DefaultChannelConfig
-
- io.netty.handler.codec.http2.AbstractHttp2StreamChannel.Http2StreamChannelConfig
-
- All Implemented Interfaces:
ChannelConfig
- Enclosing class:
- AbstractHttp2StreamChannel
private static final class AbstractHttp2StreamChannel.Http2StreamChannelConfig extends DefaultChannelConfig
ChannelConfig
so that the high and low writebuffer watermarks can reflect the outbound flow control window, without having to create a newWriteBufferWaterMark
object whenever the flow control window changes.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) boolean
autoStreamFlowControl
-
Fields inherited from class io.netty.channel.DefaultChannelConfig
channel
-
-
Constructor Summary
Constructors Constructor Description Http2StreamChannelConfig(Channel channel)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MessageSizeEstimator
getMessageSizeEstimator()
ReturnsMessageSizeEstimator
which is used for the channel to detect the size of a message.<T> T
getOption(ChannelOption<T> option)
Return the value of the givenChannelOption
java.util.Map<ChannelOption<?>,java.lang.Object>
getOptions()
Return all setChannelOption
's.ChannelConfig
setMessageSizeEstimator(MessageSizeEstimator estimator)
Set theMessageSizeEstimator
which is used for the channel to detect the size of a message.<T> boolean
setOption(ChannelOption<T> option, T value)
Sets a configuration property with the specified name and value.ChannelConfig
setRecvByteBufAllocator(RecvByteBufAllocator allocator)
Set theRecvByteBufAllocator
which is used for the channel to allocate receive buffers.-
Methods inherited from class io.netty.channel.DefaultChannelConfig
autoReadCleared, getAllocator, getConnectTimeoutMillis, getMaxMessagesPerRead, getMaxMessagesPerWrite, getOptions, getRecvByteBufAllocator, getWriteBufferHighWaterMark, getWriteBufferLowWaterMark, getWriteBufferWaterMark, getWriteSpinCount, isAutoClose, isAutoRead, setAllocator, setAutoClose, setAutoRead, setConnectTimeoutMillis, setMaxMessagesPerRead, setMaxMessagesPerWrite, setOptions, setWriteBufferHighWaterMark, setWriteBufferLowWaterMark, setWriteBufferWaterMark, setWriteSpinCount, validate
-
-
-
-
Constructor Detail
-
Http2StreamChannelConfig
Http2StreamChannelConfig(Channel channel)
-
-
Method Detail
-
getMessageSizeEstimator
public MessageSizeEstimator getMessageSizeEstimator()
Description copied from interface:ChannelConfig
ReturnsMessageSizeEstimator
which is used for the channel to detect the size of a message.- Specified by:
getMessageSizeEstimator
in interfaceChannelConfig
- Overrides:
getMessageSizeEstimator
in classDefaultChannelConfig
-
setMessageSizeEstimator
public ChannelConfig setMessageSizeEstimator(MessageSizeEstimator estimator)
Description copied from interface:ChannelConfig
Set theMessageSizeEstimator
which is used for the channel to detect the size of a message.- Specified by:
setMessageSizeEstimator
in interfaceChannelConfig
- Overrides:
setMessageSizeEstimator
in classDefaultChannelConfig
-
setRecvByteBufAllocator
public ChannelConfig setRecvByteBufAllocator(RecvByteBufAllocator allocator)
Description copied from interface:ChannelConfig
Set theRecvByteBufAllocator
which is used for the channel to allocate receive buffers.- Specified by:
setRecvByteBufAllocator
in interfaceChannelConfig
- Overrides:
setRecvByteBufAllocator
in classDefaultChannelConfig
-
getOptions
public java.util.Map<ChannelOption<?>,java.lang.Object> getOptions()
Description copied from interface:ChannelConfig
Return all setChannelOption
's.- Specified by:
getOptions
in interfaceChannelConfig
- Overrides:
getOptions
in classDefaultChannelConfig
-
getOption
public <T> T getOption(ChannelOption<T> option)
Description copied from interface:ChannelConfig
Return the value of the givenChannelOption
- Specified by:
getOption
in interfaceChannelConfig
- Overrides:
getOption
in classDefaultChannelConfig
-
setOption
public <T> boolean setOption(ChannelOption<T> option, T value)
Description copied from interface:ChannelConfig
Sets a configuration property with the specified name and value. To override this method properly, you must call the super class:public boolean setOption(ChannelOption<T> option, T value) { if (super.setOption(option, value)) { return true; } if (option.equals(additionalOption)) { .... return true; } return false; }
- Specified by:
setOption
in interfaceChannelConfig
- Overrides:
setOption
in classDefaultChannelConfig
- Returns:
true
if and only if the property has been set
-
-