public interface MaxBytesRecvByteBufAllocator extends RecvByteBufAllocator
RecvByteBufAllocator
that limits a read operation based upon a maximum value per individual read
and a maximum amount when a read operation is attempted by the event loop.RecvByteBufAllocator.DelegatingHandle, RecvByteBufAllocator.ExtendedHandle, RecvByteBufAllocator.Handle
限定符和类型 | 方法和说明 |
---|---|
int |
maxBytesPerIndividualRead()
Returns the maximum number of bytes to read per individual read operation.
|
MaxBytesRecvByteBufAllocator |
maxBytesPerIndividualRead(int maxBytesPerIndividualRead)
Sets the maximum number of bytes to read per individual read operation.
|
int |
maxBytesPerRead()
Returns the maximum number of bytes to read per read loop.
|
MaxBytesRecvByteBufAllocator |
maxBytesPerRead(int maxBytesPerRead)
Sets the maximum number of bytes to read per read loop.
|
java.util.Map.Entry<java.lang.Integer,java.lang.Integer> |
maxBytesPerReadPair()
Atomic way to get the maximum number of bytes to read for a read loop and per individual read operation.
|
MaxBytesRecvByteBufAllocator |
maxBytesPerReadPair(int maxBytesPerRead,
int maxBytesPerIndividualRead)
Sets the maximum number of bytes to read for a read loop and per individual read operation.
|
newHandle
int maxBytesPerRead()
channelRead()
event.
If this value is greater than 1, an event loop might attempt to read multiple times to procure bytes.MaxBytesRecvByteBufAllocator maxBytesPerRead(int maxBytesPerRead)
int maxBytesPerIndividualRead()
channelRead()
event.
If this value is greater than 1, an event loop might attempt to read multiple times to procure bytes.MaxBytesRecvByteBufAllocator maxBytesPerIndividualRead(int maxBytesPerIndividualRead)
java.util.Map.Entry<java.lang.Integer,java.lang.Integer> maxBytesPerReadPair()
maxBytesPerRead()
. The Value is from maxBytesPerIndividualRead()
MaxBytesRecvByteBufAllocator maxBytesPerReadPair(int maxBytesPerRead, int maxBytesPerIndividualRead)
maxBytesPerRead
- see maxBytesPerRead(int)
maxBytesPerIndividualRead
- see maxBytesPerIndividualRead(int)