Class ConnectionImpl

  • All Implemented Interfaces:
    Connection

    public class ConnectionImpl
    extends java.lang.Object
    implements Connection
    • Constructor Detail

      • ConnectionImpl

        public ConnectionImpl​(NetworkConnection core_connection,
                              boolean incoming)
    • Method Detail

      • connect

        public void connect​(ConnectionListener listener)
        Description copied from interface: Connection
        Connect this connection's transport, i.e. establish the peer connection. If this connection is already established (from an incoming connection for example), then this provides a mechanism to register the connection listener, in which case connectSuccess() will be called immediately.
        Specified by:
        connect in interface Connection
        Parameters:
        listener - notified on connect success or failure
      • close

        public void close()
        Description copied from interface: Connection
        Close and shutdown this connection.
        Specified by:
        close in interface Connection
      • startMessageProcessing

        public void startMessageProcessing()
        Description copied from interface: Connection
        Begin processing incoming and outgoing message queues.
        Specified by:
        startMessageProcessing in interface Connection
      • isIncoming

        public boolean isIncoming()
        Description copied from interface: Connection
        Returns true if the connection represents an incoming connection.
        Specified by:
        isIncoming in interface Connection
      • getString

        public java.lang.String getString()
        Description copied from interface: Connection
        descriptive text for the connection
        Specified by:
        getString in interface Connection
        Returns: