org.apache.hc.client5.http.config

## Class ConnectionConfig

- java.lang.Object
- - org.apache.hc.client5.http.config.ConnectionConfig

- All Implemented Interfaces:
    Cloneable

      @Contract(threading=IMMUTABLE)
      public class ConnectionConfig
      extends Object
      implements Cloneable

  Immutable class encapsulating connection initialization and management settings.
  Since:
    5.2

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `ConnectionConfig.Builder`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static ConnectionConfig` | `DEFAULT`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `ConnectionConfig()` Intended for CDI compatibility

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected ConnectionConfig` | `clone()`
    `static ConnectionConfig.Builder` | `copy(ConnectionConfig config)`
    `static ConnectionConfig.Builder` | `custom()`
    `org.apache.hc.core5.util.Timeout` | `getConnectTimeout()`
    `org.apache.hc.core5.util.Timeout` | `getSocketTimeout()`
    `org.apache.hc.core5.util.TimeValue` | `getTimeToLive()`
    `org.apache.hc.core5.util.TimeValue` | `getValidateAfterInactivity()`
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### DEFAULT

          public static final ConnectionConfig DEFAULT

  - ### Constructor Detail

    - #### ConnectionConfig

          protected ConnectionConfig()

      Intended for CDI compatibility

  - ### Method Detail

    - #### getSocketTimeout

          public org.apache.hc.core5.util.Timeout getSocketTimeout()

      See Also:
        `ConnectionConfig.Builder.setSocketTimeout(Timeout)`

    - #### getConnectTimeout

          public org.apache.hc.core5.util.Timeout getConnectTimeout()

      See Also:
        `ConnectionConfig.Builder.setConnectTimeout(Timeout)`

    - #### getValidateAfterInactivity

          public org.apache.hc.core5.util.TimeValue getValidateAfterInactivity()

      See Also:
        `ConnectionConfig.Builder.setValidateAfterInactivity(TimeValue)`

    - #### getTimeToLive

          public org.apache.hc.core5.util.TimeValue getTimeToLive()

      See Also:
        `(TimeValue)`

    - #### clone

          protected ConnectionConfig clone()
                                    throws CloneNotSupportedException

      Overrides:
        `clone` in class `Object`
      Throws:
        `CloneNotSupportedException`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

    - #### custom

          public static ConnectionConfig.Builder custom()

    - #### copy

          public static ConnectionConfig.Builder copy(ConnectionConfig config)

Copyright © 1999–2021 The Apache Software Foundation. All rights reserved.