Class Endpoint<E>

  • Type Parameters:
    E - the address type, for example for TCP transport it's SocketAddress
    Direct Known Subclasses:
    EndpointKey

    public abstract class Endpoint<E>
    extends Object
    The abstract class, which describes a pool endpoint and has a method, which creates new Connection to the endpoint.
    Author:
    Alexey Stashok
    • Constructor Detail

      • Endpoint

        public Endpoint()
    • Method Detail

      • getId

        public abstract Object getId()
      • connect

        public abstract org.glassfish.grizzly.GrizzlyFuture<org.glassfish.grizzly.Connection> connect()
      • onConnect

        protected void onConnect​(org.glassfish.grizzly.Connection connection,
                                 SingleEndpointPool<E> pool)
        The method is called, once new Connection related to the Endpoint is established.
        Parameters:
        connection - the Connection
        pool - the pool, to which the Connection is bound
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object