|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectxsul.http_client.HttpClientConnectionManager
xsul.http_client.HttpClientReuseLastConnectionManager
Manages connection.
NOTE: this class is multi-thread safe however for good performance is shoul d
used from only one thread that needs to conenct multiple time to the smae host:port
as this manager will reuse such connection.
| Method Summary | |
HttpClientRequest |
connect(java.lang.String host,
int port,
int timeout)
As defiend in Socket a timeout of zero is interpreted as an infinite timeout |
static HttpClientConnectionManager |
newInstance()
|
static HttpClientConnectionManager |
newInstance(ClientSocketFactory socketFactory)
|
void |
notifyConnectionForReuse(ClientSocketConnection conn)
This method is called by HttpClientRequest/Response when HTTP request/response is finished and it is safe to assume that thsi particular conenctions is finished |
void |
shutdownAndReclaimResources()
This method should be overriden by subclasses to free any resources that were not released. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
public static HttpClientConnectionManager newInstance()
public static HttpClientConnectionManager newInstance(ClientSocketFactory socketFactory)
public HttpClientRequest connect(java.lang.String host,
int port,
int timeout)
throws HttpClientException
connect in class HttpClientConnectionManagerHttpClientException
public void notifyConnectionForReuse(ClientSocketConnection conn)
throws HttpClientException
HttpClientConnectionManager
notifyConnectionForReuse in class HttpClientConnectionManagerHttpClientException
public void shutdownAndReclaimResources()
throws HttpClientException
HttpClientConnectionManager
shutdownAndReclaimResources in class HttpClientConnectionManagerHttpClientException
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||