Class ClientConfig

java.lang.Object
io.github.mahmoudimus.quic.connection.ClientConfig

public final class ClientConfig extends Object
How a client connects: its TLS configuration (trust, server name, ALPN, 0-RTT), the transport settings, the QUIC version and the SessionCache that keeps session tickets and NEW_TOKEN tokens between connections. Immutable and shareable.
  • Method Details

    • sessionCache

      public SessionCache sessionCache()
      The cache of session tickets and tokens connections use.
      Returns:
      the cache, or null to leave it to the caller (QuicClient then uses one of its own)
    • builder

      public static ClientConfig.Builder builder(TlsConfig tls)
      A builder.
      Parameters:
      tls - the TLS configuration, with ALPN and the trust to check the server with
      Returns:
      a new builder
    • tls

      public TlsConfig tls()
      The TLS configuration.
      Returns:
      the configuration
    • transport

      public TransportConfig transport()
      The transport settings.
      Returns:
      the settings
    • version

      public QuicVersion version()
      The QUIC version connections start with.
      Returns:
      the version