Class HttpConnectionParams

java.lang.Object
org.apache.http.params.HttpConnectionParams
All Implemented Interfaces:
CoreConnectionPNames

@Deprecated public final class HttpConnectionParams extends Object implements CoreConnectionPNames
Deprecated.
(4.3) use configuration classes provided 'org.apache.http.config' and 'org.apache.http.client.config'
Utility class for accessing connection parameters in HttpParams.
Since:
4.0
  • Method Details

    • getSoTimeout

      public static int getSoTimeout(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.SO_TIMEOUT parameter. If not set, defaults to 0.
      Parameters:
      params - HTTP parameters.
      Returns:
      SO_TIMEOUT.
    • setSoTimeout

      public static void setSoTimeout(HttpParams params, int timeout)
      Deprecated.
      Sets value of the CoreConnectionPNames.SO_TIMEOUT parameter.
      Parameters:
      params - HTTP parameters.
      timeout - SO_TIMEOUT.
    • getSoReuseaddr

      public static boolean getSoReuseaddr(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.SO_REUSEADDR parameter. If not set, defaults to false.
      Parameters:
      params - HTTP parameters.
      Returns:
      SO_REUSEADDR.
      Since:
      4.1
    • setSoReuseaddr

      public static void setSoReuseaddr(HttpParams params, boolean reuseaddr)
      Deprecated.
      Sets value of the CoreConnectionPNames.SO_REUSEADDR parameter.
      Parameters:
      params - HTTP parameters.
      reuseaddr - SO_REUSEADDR.
      Since:
      4.1
    • getTcpNoDelay

      public static boolean getTcpNoDelay(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.TCP_NODELAY parameter. If not set, defaults to true.
      Parameters:
      params - HTTP parameters.
      Returns:
      Nagle's algorithm flag
    • setTcpNoDelay

      public static void setTcpNoDelay(HttpParams params, boolean value)
      Deprecated.
      Sets value of the CoreConnectionPNames.TCP_NODELAY parameter.
      Parameters:
      params - HTTP parameters.
      value - Nagle's algorithm flag
    • getSocketBufferSize

      public static int getSocketBufferSize(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.SOCKET_BUFFER_SIZE parameter. If not set, defaults to -1.
      Parameters:
      params - HTTP parameters.
      Returns:
      socket buffer size
    • setSocketBufferSize

      public static void setSocketBufferSize(HttpParams params, int size)
      Deprecated.
      Sets value of the CoreConnectionPNames.SOCKET_BUFFER_SIZE parameter.
      Parameters:
      params - HTTP parameters.
      size - socket buffer size
    • getLinger

      public static int getLinger(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.SO_LINGER parameter. If not set, defaults to -1.
      Parameters:
      params - HTTP parameters.
      Returns:
      SO_LINGER.
    • setLinger

      public static void setLinger(HttpParams params, int value)
      Deprecated.
      Sets value of the CoreConnectionPNames.SO_LINGER parameter.
      Parameters:
      params - HTTP parameters.
      value - SO_LINGER.
    • getConnectionTimeout

      public static int getConnectionTimeout(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.CONNECTION_TIMEOUT parameter. If not set, defaults to 0.
      Parameters:
      params - HTTP parameters.
      Returns:
      connect timeout.
    • setConnectionTimeout

      public static void setConnectionTimeout(HttpParams params, int timeout)
      Deprecated.
      Sets value of the CoreConnectionPNames.CONNECTION_TIMEOUT parameter.
      Parameters:
      params - HTTP parameters.
      timeout - connect timeout.
    • isStaleCheckingEnabled

      public static boolean isStaleCheckingEnabled(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.STALE_CONNECTION_CHECK parameter. If not set, defaults to true.
      Parameters:
      params - HTTP parameters.
      Returns:
      stale connection check flag.
    • setStaleCheckingEnabled

      public static void setStaleCheckingEnabled(HttpParams params, boolean value)
      Deprecated.
      Sets value of the CoreConnectionPNames.STALE_CONNECTION_CHECK parameter.
      Parameters:
      params - HTTP parameters.
      value - stale connection check flag.
    • getSoKeepalive

      public static boolean getSoKeepalive(HttpParams params)
      Deprecated.
      Obtains value of the CoreConnectionPNames.SO_KEEPALIVE parameter. If not set, defaults to false.
      Parameters:
      params - HTTP parameters.
      Returns:
      SO_KEEPALIVE.
      Since:
      4.2
    • setSoKeepalive

      public static void setSoKeepalive(HttpParams params, boolean enableKeepalive)
      Deprecated.
      Sets value of the CoreConnectionPNames.SO_KEEPALIVE parameter.
      Parameters:
      params - HTTP parameters.
      enableKeepalive - SO_KEEPALIVE.
      Since:
      4.2