Interface Client

  • All Known Implementing Classes:
    NioClient, TcpClient

    public interface Client
    Defines common operations for clients (TCP or NIO)
    Since:
    3.6.5
    Author:
    Bela Ban
    • Method Detail

      • localAddress

        Address localAddress()
      • remoteAddress

        Address remoteAddress()
      • isOpen

        boolean isOpen()
      • isConnected

        boolean isConnected()
      • send

        void send​(byte[] data,
                  int offset,
                  int length)
           throws java.lang.Exception
        Sends data to the remote server. The server's address must have been set before.
        Throws:
        java.lang.Exception
      • send

        void send​(java.nio.ByteBuffer data)
           throws java.lang.Exception
        Sends data to the remote server. The server's address must have been set before.
        Throws:
        java.lang.Exception