|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.http.params.HttpConnectionParams
public final class HttpConnectionParams
An adaptor for accessing connection parameters in HttpParams
.
Note that the implements relation to CoreConnectionPNames
is for compatibility with existing application code only. References to
the parameter names should use the interface, not this class.
Field Summary |
---|
Fields inherited from interface org.apache.http.params.CoreConnectionPNames |
---|
CONNECTION_TIMEOUT, MAX_HEADER_COUNT, MAX_LINE_LENGTH, SO_LINGER, SO_TIMEOUT, SOCKET_BUFFER_SIZE, STALE_CONNECTION_CHECK, TCP_NODELAY |
Method Summary | |
---|---|
static int |
getConnectionTimeout(HttpParams params)
Returns the timeout until a connection is etablished. |
static int |
getLinger(HttpParams params)
Returns linger-on-close timeout. |
static int |
getSocketBufferSize(HttpParams params)
|
static int |
getSoTimeout(HttpParams params)
Returns the default socket timeout (SO_TIMEOUT) in milliseconds which is the timeout for waiting for data. |
static boolean |
getTcpNoDelay(HttpParams params)
Tests if Nagle's algorithm is to be used. |
static boolean |
isStaleCheckingEnabled(HttpParams params)
Tests whether stale connection check is to be used. |
static void |
setConnectionTimeout(HttpParams params,
int timeout)
Sets the timeout until a connection is etablished. |
static void |
setLinger(HttpParams params,
int value)
Returns linger-on-close timeout. |
static void |
setSocketBufferSize(HttpParams params,
int size)
|
static void |
setSoTimeout(HttpParams params,
int timeout)
Sets the default socket timeout (SO_TIMEOUT) in milliseconds which is the timeout for waiting for data. |
static void |
setStaleCheckingEnabled(HttpParams params,
boolean value)
Defines whether stale connection check is to be used. |
static void |
setTcpNoDelay(HttpParams params,
boolean value)
Determines whether Nagle's algorithm is to be used. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static int getSoTimeout(HttpParams params)
public static void setSoTimeout(HttpParams params, int timeout)
timeout
- Timeout in millisecondspublic static boolean getTcpNoDelay(HttpParams params)
public static void setTcpNoDelay(HttpParams params, boolean value)
value
- true if the Nagle's algorithm is to NOT be used
(that is enable TCP_NODELAY), false otherwise.public static int getSocketBufferSize(HttpParams params)
public static void setSocketBufferSize(HttpParams params, int size)
public static int getLinger(HttpParams params)
public static void setLinger(HttpParams params, int value)
value
- the linger-on-close timeoutpublic static int getConnectionTimeout(HttpParams params)
public static void setConnectionTimeout(HttpParams params, int timeout)
timeout
- Timeout in milliseconds.public static boolean isStaleCheckingEnabled(HttpParams params)
public static void setStaleCheckingEnabled(HttpParams params, boolean value)
value
- true if stale connection check is to be used,
false otherwise.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |