public abstract class AbstractOioChannel extends AbstractChannel
Channel
实现的抽象基类
AbstractChannel.AbstractUnsafe
Channel.Unsafe
Modifier and Type | Field and Description |
---|---|
protected static int |
SO_TIMEOUT |
Modifier | Constructor and Description |
---|---|
protected |
AbstractOioChannel(Channel parent) |
Modifier and Type | Method and Description |
---|---|
protected void |
clearReadPending()
将等待读取设置为
false 。
|
protected void |
doBeginRead()
安排读取操作。
|
protected abstract void |
doConnect(java.net.SocketAddress remoteAddress, java.net.SocketAddress localAddress)
如果指定了localAddress,则使用给定的localAddress连接到远程对等,否则连接到
null 。
|
protected abstract void |
doRead() |
protected boolean |
isCompatible(EventLoop loop)
如果给定的 EventLoop 与此实例兼容,则返回true 。
|
protected boolean |
isReadPending()
已过时。
不再支持。
不再支持。
|
protected AbstractChannel.AbstractUnsafe |
newUnsafe()
创建一个新的 AbstractChannel.AbstractUnsafe 实例,该实例将用于Channel 的生命周期
|
protected void |
setReadPending(boolean readPending)
已过时。
如果合适,请使用
clearReadPending() 。
不再支持。
|
alloc, bind, bind, bytesBeforeUnwritable, bytesBeforeWritable, close, close, closeFuture, compareTo, connect, connect, connect, connect, deregister, deregister, disconnect, disconnect, doBind, doClose, doDeregister, doDisconnect, doRegister, doShutdownOutput, doWrite, equals, eventLoop, filterOutboundMessage, flush, hashCode, id, invalidateLocalAddress, invalidateRemoteAddress, isRegistered, isWritable, localAddress, localAddress0, newChannelPipeline, newFailedFuture, newId, newProgressivePromise, newPromise, newSucceededFuture, parent, pipeline, read, remoteAddress, remoteAddress0, toString, unsafe, voidPromise, write, write, writeAndFlush, writeAndFlush
attr, hasAttr
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
attr, hasAttr
protected static final int SO_TIMEOUT
protected AbstractOioChannel(Channel parent)
protected AbstractChannel.AbstractUnsafe newUnsafe()
AbstractChannel
AbstractChannel.AbstractUnsafe
实例,该实例将用于Channel
的生命周期
newUnsafe
在课堂上
AbstractChannel
protected boolean isCompatible(EventLoop loop)
AbstractChannel
EventLoop
与此实例兼容,则返回true
。
isCompatible
在课堂上
AbstractChannel
protected abstract void doConnect(java.net.SocketAddress remoteAddress, java.net.SocketAddress localAddress) throws java.lang.Exception
null
。
java.lang.Exception
protected void doBeginRead() throws java.lang.Exception
AbstractChannel
doBeginRead
在课堂上
AbstractChannel
java.lang.Exception
protected abstract void doRead()
@Deprecated protected boolean isReadPending()
@Deprecated protected void setReadPending(boolean readPending)
protected final void clearReadPending()
false
。
Copyright © 2008–2018 The Netty Project. All rights reserved.