Class UnixChannelUtil

java.lang.Object
io.netty.channel.unix.UnixChannelUtil

public final class UnixChannelUtil extends java.lang.Object
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static java.net.InetSocketAddress
    computeRemoteAddr(java.net.InetSocketAddress remoteAddr, java.net.InetSocketAddress osRemoteAddr)
     
    static boolean
    deleteDomainSocketFile(java.lang.String path)
    Delete the file at path but only if it is not a regular file, directory or symbolic link (i.e.
    static boolean
    Checks if the specified buffer has memory address or is composed of n(n invalid input: '<'= IOV_MAX) NIO direct buffers.
    (package private) static boolean
    isBufferCopyNeededForWrite(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

      public static boolean isBufferCopyNeededForWrite(ByteBuf byteBuf)
      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

      static boolean isBufferCopyNeededForWrite(ByteBuf byteBuf, int iovMax)
    • deleteDomainSocketFile

      public static boolean deleteDomainSocketFile(java.lang.String path)
      Delete the file at path but 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:
      true if the file was deleted.
    • computeRemoteAddr

      public static java.net.InetSocketAddress computeRemoteAddr(java.net.InetSocketAddress remoteAddr, java.net.InetSocketAddress osRemoteAddr)