Package io.netty.channel
Class ChannelMetadata
- java.lang.Object
-
- io.netty.channel.ChannelMetadata
-
public final class ChannelMetadata extends java.lang.Object
Represents the properties of aChannel
implementation.
-
-
Constructor Summary
Constructors Constructor Description ChannelMetadata(boolean hasDisconnect)
Create a new instanceChannelMetadata(boolean hasDisconnect, int defaultMaxMessagesPerRead)
Create a new instance
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
defaultMaxMessagesPerRead()
If aMaxMessagesRecvByteBufAllocator
is in use, then this is the default value forMaxMessagesRecvByteBufAllocator.maxMessagesPerRead()
.boolean
hasDisconnect()
Returnstrue
if and only if the channel has thedisconnect()
operation that allows a user to disconnect and then callChannel.connect(SocketAddress)
again, such as UDP/IP.
-
-
-
Constructor Detail
-
ChannelMetadata
public ChannelMetadata(boolean hasDisconnect)
Create a new instance- Parameters:
hasDisconnect
-true
if and only if the channel has thedisconnect()
operation that allows a user to disconnect and then callChannel.connect(SocketAddress)
again, such as UDP/IP.
-
ChannelMetadata
public ChannelMetadata(boolean hasDisconnect, int defaultMaxMessagesPerRead)
Create a new instance- Parameters:
hasDisconnect
-true
if and only if the channel has thedisconnect()
operation that allows a user to disconnect and then callChannel.connect(SocketAddress)
again, such as UDP/IP.defaultMaxMessagesPerRead
- If aMaxMessagesRecvByteBufAllocator
is in use, then this value will be set forMaxMessagesRecvByteBufAllocator.maxMessagesPerRead()
. Must be> 0
.
-
-
Method Detail
-
hasDisconnect
public boolean hasDisconnect()
Returnstrue
if and only if the channel has thedisconnect()
operation that allows a user to disconnect and then callChannel.connect(SocketAddress)
again, such as UDP/IP.
-
defaultMaxMessagesPerRead
public int defaultMaxMessagesPerRead()
If aMaxMessagesRecvByteBufAllocator
is in use, then this is the default value forMaxMessagesRecvByteBufAllocator.maxMessagesPerRead()
.
-
-