|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.http.conn.params.HttpConnectionManagerParams
public final class HttpConnectionManagerParams
This class represents a collection of HTTP protocol parameters applicable
to client-side
connection managers
.
Field Summary | |
---|---|
static int |
DEFAULT_MAX_HOST_CONNECTIONS
The default maximum number of connections allowed per host |
static int |
DEFAULT_MAX_TOTAL_CONNECTIONS
The default maximum number of connections allowed overall |
static java.lang.String |
MAX_HOST_CONNECTIONS
Defines the maximum number of connections allowed per host configuration. |
static java.lang.String |
MAX_TOTAL_CONNECTIONS
Defines the maximum number of connections allowed overall. |
Constructor Summary | |
---|---|
HttpConnectionManagerParams()
|
Method Summary | |
---|---|
static int |
getDefaultMaxConnectionsPerHost(org.apache.http.params.HttpParams params)
Gets the default maximum number of connections allowed for a given host config. |
static int |
getMaxConnectionsPerHost(org.apache.http.params.HttpParams params,
HostConfiguration hostConfiguration)
Gets the maximum number of connections to be used for a particular host config. |
static int |
getMaxTotalConnections(org.apache.http.params.HttpParams params)
Gets the maximum number of connections allowed. |
static void |
setDefaultMaxConnectionsPerHost(org.apache.http.params.HttpParams params,
int maxHostConnections)
Sets the default maximum number of connections allowed for a given host config. |
static void |
setMaxConnectionsPerHost(org.apache.http.params.HttpParams params,
HostConfiguration hostConfiguration,
int maxHostConnections)
Sets the maximum number of connections to be used for the given host config. |
static void |
setMaxTotalConnections(org.apache.http.params.HttpParams params,
int maxTotalConnections)
Sets the maximum number of connections allowed. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int DEFAULT_MAX_HOST_CONNECTIONS
public static final int DEFAULT_MAX_TOTAL_CONNECTIONS
public static final java.lang.String MAX_HOST_CONNECTIONS
This parameter expects a value of type Map
. The value
should map instances of HostConfiguration
to integers
. The default value can be specified using
HostConfiguration.ANY_HOST_CONFIGURATION
.
public static final java.lang.String MAX_TOTAL_CONNECTIONS
This parameter expects a value of type Integer
.
Constructor Detail |
---|
public HttpConnectionManagerParams()
Method Detail |
---|
public static void setDefaultMaxConnectionsPerHost(org.apache.http.params.HttpParams params, int maxHostConnections)
maxHostConnections
- The default maximum.MAX_HOST_CONNECTIONS
public static void setMaxConnectionsPerHost(org.apache.http.params.HttpParams params, HostConfiguration hostConfiguration, int maxHostConnections)
hostConfiguration
- The host config to set the maximum for. Use
HostConfiguration.ANY_HOST_CONFIGURATION
to configure the default value
per host.maxHostConnections
- The maximum number of connections, > 0
MAX_HOST_CONNECTIONS
public static int getDefaultMaxConnectionsPerHost(org.apache.http.params.HttpParams params)
MAX_HOST_CONNECTIONS
public static int getMaxConnectionsPerHost(org.apache.http.params.HttpParams params, HostConfiguration hostConfiguration)
hostConfiguration
- The host config.
MAX_HOST_CONNECTIONS
public static void setMaxTotalConnections(org.apache.http.params.HttpParams params, int maxTotalConnections)
maxTotalConnections
- The maximum number of connections allowed.MAX_TOTAL_CONNECTIONS
public static int getMaxTotalConnections(org.apache.http.params.HttpParams params)
MAX_TOTAL_CONNECTIONS
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |