AbortableHttpRequest, Configurable, HttpExecutionAware, HttpUriRequest, org.apache.http.HttpMessage, org.apache.http.HttpRequestpublic class HttpPost extends HttpEntityEnclosingRequestBase
The HTTP POST method is defined in section 9.5 of RFC2616:
The POST method is used to request that the origin server accept the entity enclosed in the request as a new subordinate of the resource identified by the Request-URI in the Request-Line. POST is designed to allow a uniform method to cover the following functions:
- Annotation of existing resources
- Posting a message to a bulletin board, newsgroup, mailing list, or similar group of articles
- Providing a block of data, such as the result of submitting a form, to a data-handling process
- Extending a database through an append operation
| Modifier and Type | Field | Description |
|---|---|---|
static java.lang.String |
METHOD_NAME |
| Constructor | Description |
|---|---|
HttpPost() |
|
HttpPost(java.lang.String uri) |
|
HttpPost(java.net.URI uri) |
| Modifier and Type | Method | Description |
|---|---|---|
java.lang.String |
getMethod() |
Returns the HTTP method this request uses, such as
GET,
PUT, POST, or other. |
abort, completed, isAborted, reset, setCancellable, setConnectionRequest, setReleaseTriggeraddHeader, addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, headerIterator, headerIterator, removeHeader, removeHeaders, setHeader, setHeader, setHeaders, setParamsclone, expectContinue, getEntity, setEntityaddHeader, addHeader, containsHeader, getAllHeaders, getFirstHeader, getHeaders, getLastHeader, getParams, getProtocolVersion, headerIterator, headerIterator, removeHeader, removeHeaders, setHeader, setHeader, setHeaders, setParamsgetConfig, getProtocolVersion, getRequestLine, getURI, releaseConnection, setConfig, setProtocolVersion, setURI, started, toStringabort, isAbortedpublic static final java.lang.String METHOD_NAME
public HttpPost()
public HttpPost(java.net.URI uri)
public HttpPost(java.lang.String uri)
java.lang.IllegalArgumentException - if the uri is invalid.public java.lang.String getMethod()
HttpUriRequestGET,
PUT, POST, or other.getMethod in interface HttpUriRequestgetMethod in class HttpRequestBase