Class EndpointKey<E>

    • Constructor Detail

      • EndpointKey

        public EndpointKey​(Object internalKey,
                           E endpointAddress)
        Construct EndpointKey based on the given internalKey and endpoint.
        Parameters:
        internalKey - the internal key to be used in Endpoint.equals(java.lang.Object) and Endpoint.hashCode() methods
        endpointAddress - the endpoint address, that will be used by a ConnectorHandler passed to MultiEndpointPool to establish new client-side Connection
      • EndpointKey

        public EndpointKey​(Object internalKey,
                           E endpointAddress,
                           E localEndpointAddress)
        Construct EndpointKey based on the given internalKey, endpoint, and local endpoint.
        Parameters:
        internalKey - the internal key to be used in Endpoint.equals(java.lang.Object) and Endpoint.hashCode() methods
        endpointAddress - the endpoint address, that will be used by a ConnectorHandler passed to MultiEndpointPool to establish new client-side Connection
        localEndpointAddress - the local address that will be used by the ConnectorHandler to bind the local side of the outgoing connection.
      • EndpointKey

        public EndpointKey​(Object internalKey,
                           E endpointAddress,
                           org.glassfish.grizzly.ConnectorHandler<E> connectorHandler)
        Construct EndpointKey based on the given internalKey, endpoint, and ConnectorHandler.
        Parameters:
        internalKey - the internal key to be used in Endpoint.equals(java.lang.Object) and Endpoint.hashCode() methods
        endpointAddress - the endpoint address, that will be used by a ConnectorHandler passed to MultiEndpointPool to establish new client-side Connection
        connectorHandler - customized ConnectorHandler for this endpoint
      • EndpointKey

        public EndpointKey​(Object internalKey,
                           E endpointAddress,
                           E localEndpointAddress,
                           org.glassfish.grizzly.ConnectorHandler<E> connectorHandler)
        Parameters:
        internalKey - the internal key to be used in Endpoint.equals(java.lang.Object) and Endpoint.hashCode() methods
        endpointAddress - the endpoint address, that will be used by a ConnectorHandler passed to MultiEndpointPool to establish new client-side Connection
        localEndpointAddress - the local address that will be used by the ConnectorHandler to bind the local side of the outgoing connection.
        connectorHandler - customized ConnectorHandler for this endpoint
    • Method Detail

      • connect

        public org.glassfish.grizzly.GrizzlyFuture<org.glassfish.grizzly.Connection> connect()
        Specified by:
        connect in class Endpoint<E>
      • getEndpoint

        public E getEndpoint()
        Returns:
        the endpoint address, used by a ConnectorHandler passed to MultiEndpointPool to establish new client-side Connection
      • getLocalEndpoint

        public E getLocalEndpoint()
        Returns:
        the local endpoint address that be bound to when making the outgoing connection.
      • getConnectorHandler

        public org.glassfish.grizzly.ConnectorHandler<E> getConnectorHandler()
        Returns:
        a customized ConnectorHandler, which will be used to create Connections to this endpoint.