Class UnixChannelUtil
java.lang.Object
io.netty.channel.unix.UnixChannelUtil
public final class UnixChannelUtil
extends java.lang.Object
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic java.net.InetSocketAddresscomputeRemoteAddr(java.net.InetSocketAddress remoteAddr, java.net.InetSocketAddress osRemoteAddr) static booleandeleteDomainSocketFile(java.lang.String path) Delete the file atpathbut only if it is not a regular file, directory or symbolic link (i.e.static booleanisBufferCopyNeededForWrite(ByteBuf byteBuf) Checks if the specified buffer has memory address or is composed of n(n invalid input: '<'= IOV_MAX) NIO direct buffers.(package private) static booleanisBufferCopyNeededForWrite(ByteBuf byteBuf, int iovMax) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
UnixChannelUtil
private UnixChannelUtil()
-
-
Method Details
-
isBufferCopyNeededForWrite
Checks if the specified buffer has memory address or is composed of n(n invalid input: '<'= IOV_MAX) NIO direct buffers. (We check this because otherwise we need to make it a new direct buffer.) -
isBufferCopyNeededForWrite
-
deleteDomainSocketFile
public static boolean deleteDomainSocketFile(java.lang.String path) Delete the file atpathbut only if it is not a regular file, directory or symbolic link (i.e. it is a socket inode as left behind by a bound domain socket). Symbolic links are never followed.- Returns:
trueif the file was deleted.
-
computeRemoteAddr
public static java.net.InetSocketAddress computeRemoteAddr(java.net.InetSocketAddress remoteAddr, java.net.InetSocketAddress osRemoteAddr)
-