Class ClientConnectionFactory.Info

All Implemented Interfaces:
Container, Destroyable, Dumpable, Dumpable.DumpableContainer, LifeCycle
Direct Known Subclasses:
ClientConnectionFactoryOverHTTP2.HTTP2, ClientConnectionFactoryOverHTTP3.HTTP3
Enclosing interface:
ClientConnectionFactory

public abstract static class ClientConnectionFactory.Info extends ContainerLifeCycle

A holder for a list of protocol strings identifiers (for example ["h2", "h2-17", "h2-16"]) and a ClientConnectionFactory that creates connections that speak an application protocol such as HTTP.

  • Constructor Details

  • Method Details

    • getProtocols

      public abstract List<String> getProtocols(boolean secure)
      Parameters:
      secure - true for the secure protocol identifiers, false for the clear-text protocol identifiers
      Returns:
      a list of protocol string identifiers
    • getClientConnectionFactory

      public ClientConnectionFactory getClientConnectionFactory()
      Returns:
      the ClientConnectionFactory that speaks the protocol
    • newTransport

      public abstract Transport newTransport()
      Returns:
      the default Transport used by the protocol
    • matches

      public boolean matches(List<String> candidates, boolean secure)

      Tests whether one of the protocol identifiers of this class is also present in the given candidates list.

      Parameters:
      candidates - the candidates to match against
      secure - whether the protocol should be a secure one
      Returns:
      whether one of the protocols of this class is present in the candidates
    • upgrade

      public void upgrade(EndPoint endPoint, Map<String,Object> context)

      Upgrades the given EndPoint to the protocol represented by this class.

      Parameters:
      endPoint - the EndPoint to upgrade
      context - the context information to perform the upgrade