Package org.apache.http.client.methods
Interface HttpUriRequest
- All Superinterfaces:
HttpMessage,HttpRequest
- All Known Implementing Classes:
EntityEnclosingRequestWrapper,HttpDelete,HttpEntityEnclosingRequestBase,HttpGet,HttpHead,HttpOptions,HttpPost,HttpPut,HttpRequestBase,HttpTrace,RequestWrapper
public interface HttpUriRequest extends HttpRequest
Extended version of the
HttpRequest interface that provides
convenience methods to access request properties such as request URI
and method type.- Since:
- 4.0
- Version:
- $Revision: 659191 $
- Author:
- Oleg Kalnichevski
-
Method Summary
Modifier and Type Method Description voidabort()Aborts execution of the request.StringgetMethod()Returns the HTTP method this request uses, such asGET,PUT,POST, or other.URIgetURI()Returns the URI this request uses, such ashttp://example.org/path/to/file.booleanisAborted()Tests if the request execution has been aborted.Methods inherited from interface org.apache.http.HttpMessage
addHeader, addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, getProtocolVersion, headerIterator, headerIterator, removeHeader, removeHeaders, setHeader, setHeader, setHeaders, setParams
-
Method Details
-
getMethod
String getMethod()Returns the HTTP method this request uses, such asGET,PUT,POST, or other. -
getURI
URI getURI()Returns the URI this request uses, such ashttp://example.org/path/to/file. -
abort
Aborts execution of the request.- Throws:
UnsupportedOperationException- if the abort operation is not supported / cannot be implemented.
-
isAborted
boolean isAborted()Tests if the request execution has been aborted.- Returns:
trueif the request execution has been aborted,falseotherwise.
-