|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.http.message.AbstractHttpMessage
org.apache.http.impl.client.RequestWrapper
@NotThreadSafe public class RequestWrapper
A wrapper class for HttpRequest
s that can be used to change
properties of the current request without modifying the original
object.
Field Summary |
---|
Fields inherited from class org.apache.http.message.AbstractHttpMessage |
---|
headergroup, params |
Constructor Summary | |
---|---|
RequestWrapper(org.apache.http.HttpRequest request)
|
Method Summary | |
---|---|
void |
abort()
Aborts execution of the request. |
int |
getExecCount()
|
java.lang.String |
getMethod()
Returns the HTTP method this request uses, such as GET ,
PUT , POST , or other. |
org.apache.http.HttpRequest |
getOriginal()
|
org.apache.http.ProtocolVersion |
getProtocolVersion()
|
org.apache.http.RequestLine |
getRequestLine()
|
java.net.URI |
getURI()
Returns the URI this request uses, such as http://example.org/path/to/file . |
void |
incrementExecCount()
|
boolean |
isAborted()
Tests if the request execution has been aborted. |
boolean |
isRepeatable()
|
void |
resetHeaders()
|
void |
setMethod(java.lang.String method)
|
void |
setProtocolVersion(org.apache.http.ProtocolVersion version)
|
void |
setURI(java.net.URI uri)
|
Methods inherited from class org.apache.http.message.AbstractHttpMessage |
---|
addHeader, addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, headerIterator, headerIterator, removeHeader, removeHeaders, setHeader, setHeader, setHeaders, setParams |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.http.HttpMessage |
---|
addHeader, addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, headerIterator, headerIterator, removeHeader, removeHeaders, setHeader, setHeader, setHeaders, setParams |
Constructor Detail |
---|
public RequestWrapper(org.apache.http.HttpRequest request) throws org.apache.http.ProtocolException
org.apache.http.ProtocolException
Method Detail |
---|
public void resetHeaders()
public java.lang.String getMethod()
HttpUriRequest
GET
,
PUT
, POST
, or other.
getMethod
in interface HttpUriRequest
public void setMethod(java.lang.String method)
public org.apache.http.ProtocolVersion getProtocolVersion()
getProtocolVersion
in interface org.apache.http.HttpMessage
public void setProtocolVersion(org.apache.http.ProtocolVersion version)
public java.net.URI getURI()
HttpUriRequest
http://example.org/path/to/file
.
Implementations are encouraged to return the URI that was initially requested.
To find the final URI after any redirects have been processed, please see the section entitled HTTP execution context in the HttpClient Tutorial
getURI
in interface HttpUriRequest
public void setURI(java.net.URI uri)
public org.apache.http.RequestLine getRequestLine()
getRequestLine
in interface org.apache.http.HttpRequest
public void abort() throws java.lang.UnsupportedOperationException
HttpUriRequest
abort
in interface HttpUriRequest
java.lang.UnsupportedOperationException
- if the abort operation
is not supported / cannot be implemented.public boolean isAborted()
HttpUriRequest
isAborted
in interface HttpUriRequest
true
if the request execution has been aborted,
false
otherwise.public org.apache.http.HttpRequest getOriginal()
public boolean isRepeatable()
public int getExecCount()
public void incrementExecCount()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |