|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.commons.httpclient.HttpMethodBase | +--org.apache.commons.httpclient.ConnectMethod
Wraps another method to tunnel through a proxy.
Field Summary | |
static String |
NAME
the name of this method |
Fields inherited from class org.apache.commons.httpclient.HttpMethodBase |
USER_AGENT |
Constructor Summary | |
ConnectMethod(HttpMethod method)
Create a connect method wrapping the existing method |
Method Summary | |
int |
execute(HttpState state,
HttpConnection conn)
Execute this method by tunnelling and then executing the wrapped method. |
String |
getName()
Provide the name of this method. |
protected void |
writeRequestHeaders(HttpState state,
HttpConnection conn)
Writes a minimal set of headers to the proxy. |
protected void |
writeRequestLine(HttpState state,
HttpConnection conn)
Special Connect request. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String NAME
Constructor Detail |
public ConnectMethod(HttpMethod method)
method
- the method
to execute after connecting
to the serverMethod Detail |
public String getName()
name
of this method.
getName
in interface HttpMethod
getName
in class HttpMethodBase
public int execute(HttpState state, HttpConnection conn) throws IOException, HttpException
execute
in interface HttpMethod
execute
in class HttpMethodBase
state
- the current http stateconn
- the connection to write to
HttpException
- when an error occurs writing the headers
IOException
- when an error occurs writing the headersprotected void writeRequestHeaders(HttpState state, HttpConnection conn) throws HttpException, IOException
writeRequestHeaders
in class HttpMethodBase
state
- the current http stateconn
- the connection to write to
HttpException
- when an error occurs writing the headers
IOException
- when an error occurs writing the headersHttpMethodBase.addRequestHeaders(org.apache.commons.httpclient.HttpState, org.apache.commons.httpclient.HttpConnection)
,
HttpMethodBase.getRequestHeaders()
protected void writeRequestLine(HttpState state, HttpConnection conn) throws IOException, HttpException
writeRequestLine
in class HttpMethodBase
state
- the current http stateconn
- the connection to write to
IOException
- when an error occurs writing the request
HttpException
- when an error occurs writing the requestHttpMethodBase.generateRequestLine(org.apache.commons.httpclient.HttpConnection, java.lang.String, java.lang.String, java.lang.String, java.lang.String)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |