public interface SocketChannel extends DuplexChannel
Channel
.Channel.Unsafe
限定符和类型 | 方法和说明 |
---|---|
SocketChannelConfig |
config()
Returns the configuration of this channel.
|
java.net.InetSocketAddress |
localAddress()
Returns the local address where this channel is bound to.
|
ServerSocketChannel |
parent()
Returns the parent of this channel.
|
java.net.InetSocketAddress |
remoteAddress()
Returns the remote address where this channel is connected to.
|
isInputShutdown, isOutputShutdown, shutdownOutput, shutdownOutput
alloc, bind, bind, close, close, closeFuture, connect, connect, connect, connect, deregister, deregister, disconnect, disconnect, eventLoop, flush, isActive, isOpen, isRegistered, isWritable, metadata, newFailedFuture, newProgressivePromise, newPromise, newSucceededFuture, pipeline, read, unsafe, voidPromise, write, write, writeAndFlush, writeAndFlush
attr
ServerSocketChannel parent()
Channel
SocketChannelConfig config()
Channel
java.net.InetSocketAddress localAddress()
Channel
SocketAddress
is supposed to be down-cast into more concrete
type such as InetSocketAddress
to retrieve the detailed
information.localAddress
在接口中 Channel
null
if this channel is not bound.java.net.InetSocketAddress remoteAddress()
Channel
SocketAddress
is supposed to be down-cast into more
concrete type such as InetSocketAddress
to retrieve the detailed
information.remoteAddress
在接口中 Channel
null
if this channel is not connected.
If this channel is not connected but it can receive messages
from arbitrary remote addresses (e.g. DatagramChannel
,
use DefaultAddressedEnvelope.recipient()
to determine
the origination of the received message as this method will
return null
.