public final class EpollDomainSocketChannel extends AbstractEpollStreamChannel implements DomainSocketChannel
AbstractEpollStreamChannel.SpliceInTask
Modifier and Type | Field and Description |
---|---|
protected boolean |
active |
protected int |
flags |
Constructor and Description |
---|
EpollDomainSocketChannel() |
EpollDomainSocketChannel(io.netty.channel.Channel parent,
FileDescriptor fd)
Deprecated.
|
EpollDomainSocketChannel(io.netty.channel.Channel parent,
Socket fd) |
EpollDomainSocketChannel(FileDescriptor fd)
Deprecated.
Use
EpollDomainSocketChannel(Socket, boolean) .
Creates a new |
EpollDomainSocketChannel(Socket fd,
boolean active)
Creates a new
EpollDomainSocketChannel from an existing FileDescriptor |
Modifier and Type | Method and Description |
---|---|
protected static void |
checkResolvable(InetSocketAddress addr) |
EpollDomainSocketChannelConfig |
config() |
protected void |
doBeginRead() |
protected void |
doBind(SocketAddress localAddress) |
protected boolean |
doConnect(SocketAddress remoteAddress,
SocketAddress localAddress)
Connect to the remote peer
|
protected void |
doDeregister() |
protected void |
doDisconnect() |
protected int |
doReadBytes(io.netty.buffer.ByteBuf byteBuf)
Read bytes into the given
ByteBuf and return the amount. |
protected void |
doRegister() |
protected int |
doWriteBytes(io.netty.buffer.ByteBuf buf,
int writeSpinCount) |
protected boolean |
doWriteSingle(io.netty.channel.ChannelOutboundBuffer in,
int writeSpinCount) |
Socket |
fd()
Returns the
FileDescriptor that is used by this Channel . |
protected Object |
filterOutboundMessage(Object msg) |
boolean |
isActive() |
protected boolean |
isCompatible(io.netty.channel.EventLoop loop) |
boolean |
isOpen() |
DomainSocketAddress |
localAddress() |
protected DomainSocketAddress |
localAddress0() |
protected io.netty.buffer.ByteBuf |
newDirectBuffer(io.netty.buffer.ByteBuf buf)
Returns an off-heap copy of the specified
ByteBuf , and releases the original one. |
protected io.netty.buffer.ByteBuf |
newDirectBuffer(Object holder,
io.netty.buffer.ByteBuf buf)
Returns an off-heap copy of the specified
ByteBuf , and releases the specified holder. |
protected io.netty.channel.epoll.AbstractEpollChannel.AbstractEpollUnsafe |
newUnsafe() |
PeerCredentials |
peerCredentials()
Returns the unix credentials (uid, gid, pid) of the peer
SO_PEERCRED
|
DomainSocketAddress |
remoteAddress() |
protected DomainSocketAddress |
remoteAddress0() |
doClose, doWrite, isInputShutdown, isOutputShutdown, isShutdown, metadata, shutdown, shutdown, shutdownInput, shutdownInput, shutdownOutput, shutdownOutput, spliceTo, spliceTo, spliceTo, spliceTo
alloc, bind, bind, bytesBeforeUnwritable, bytesBeforeWritable, close, close, closeFuture, compareTo, connect, connect, connect, connect, deregister, deregister, disconnect, disconnect, equals, eventLoop, flush, hashCode, id, invalidateLocalAddress, invalidateRemoteAddress, isRegistered, isWritable, newChannelPipeline, newFailedFuture, newId, newProgressivePromise, newPromise, newSucceededFuture, parent, pipeline, read, toString, unsafe, voidPromise, write, write, writeAndFlush, writeAndFlush
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
fd
isInputShutdown, isOutputShutdown, isShutdown, shutdown, shutdown, shutdownInput, shutdownInput, shutdownOutput, shutdownOutput
alloc, bytesBeforeUnwritable, bytesBeforeWritable, closeFuture, eventLoop, flush, id, isActive, isOpen, isRegistered, isWritable, metadata, parent, pipeline, read, unsafe
bind, bind, close, close, connect, connect, connect, connect, deregister, deregister, disconnect, disconnect, newFailedFuture, newProgressivePromise, newPromise, newSucceededFuture, voidPromise, write, write, writeAndFlush, writeAndFlush
compareTo
public EpollDomainSocketChannel()
@Deprecated public EpollDomainSocketChannel(io.netty.channel.Channel parent, FileDescriptor fd)
EpollDomainSocketChannel(Channel, Socket)
.@Deprecated public EpollDomainSocketChannel(FileDescriptor fd)
EpollDomainSocketChannel(Socket, boolean)
.
Creates a new EpollDomainSocketChannel
from an existing FileDescriptor
public EpollDomainSocketChannel(io.netty.channel.Channel parent, Socket fd)
public EpollDomainSocketChannel(Socket fd, boolean active)
EpollDomainSocketChannel
from an existing FileDescriptor
protected io.netty.channel.epoll.AbstractEpollChannel.AbstractEpollUnsafe newUnsafe()
newUnsafe
in class AbstractEpollStreamChannel
protected DomainSocketAddress localAddress0()
localAddress0
in class io.netty.channel.AbstractChannel
protected DomainSocketAddress remoteAddress0()
remoteAddress0
in class io.netty.channel.AbstractChannel
protected void doBind(SocketAddress localAddress) throws Exception
doBind
in class io.netty.channel.AbstractChannel
Exception
public EpollDomainSocketChannelConfig config()
config
in interface io.netty.channel.Channel
config
in interface DomainSocketChannel
protected boolean doConnect(SocketAddress remoteAddress, SocketAddress localAddress) throws Exception
AbstractEpollStreamChannel
doConnect
in class AbstractEpollStreamChannel
Exception
public DomainSocketAddress remoteAddress()
remoteAddress
in interface io.netty.channel.Channel
remoteAddress
in interface DomainSocketChannel
remoteAddress
in class io.netty.channel.AbstractChannel
public DomainSocketAddress localAddress()
localAddress
in interface io.netty.channel.Channel
localAddress
in interface DomainSocketChannel
localAddress
in class io.netty.channel.AbstractChannel
protected boolean doWriteSingle(io.netty.channel.ChannelOutboundBuffer in, int writeSpinCount) throws Exception
doWriteSingle
in class AbstractEpollStreamChannel
Exception
protected Object filterOutboundMessage(Object msg)
filterOutboundMessage
in class AbstractEpollStreamChannel
public PeerCredentials peerCredentials() throws IOException
IOException
public final Socket fd()
UnixChannel
FileDescriptor
that is used by this Channel
.fd
in interface UnixChannel
public boolean isActive()
isActive
in interface io.netty.channel.Channel
protected void doDisconnect() throws Exception
doDisconnect
in class io.netty.channel.AbstractChannel
Exception
protected boolean isCompatible(io.netty.channel.EventLoop loop)
isCompatible
in class io.netty.channel.AbstractChannel
public boolean isOpen()
isOpen
in interface io.netty.channel.Channel
protected void doDeregister() throws Exception
doDeregister
in class io.netty.channel.AbstractChannel
Exception
protected final void doBeginRead() throws Exception
doBeginRead
in class io.netty.channel.AbstractChannel
Exception
protected void doRegister() throws Exception
doRegister
in class io.netty.channel.AbstractChannel
Exception
protected final io.netty.buffer.ByteBuf newDirectBuffer(io.netty.buffer.ByteBuf buf)
ByteBuf
, and releases the original one.protected final io.netty.buffer.ByteBuf newDirectBuffer(Object holder, io.netty.buffer.ByteBuf buf)
ByteBuf
, and releases the specified holder.
The caller must ensure that the holder releases the original ByteBuf
when the holder is released by
this method.protected static void checkResolvable(InetSocketAddress addr)
protected final int doReadBytes(io.netty.buffer.ByteBuf byteBuf) throws Exception
ByteBuf
and return the amount.Exception
Copyright © 2008–2017 The Netty Project. All rights reserved.