public class DefaultRequest extends AbstractHttpMessage implements Request
| Constructor and Description |
|---|
DefaultRequest(HttpMethod method,
String href) |
DefaultRequest(HttpMethod method,
String href,
QueryString query) |
DefaultRequest(HttpMethod method,
String href,
QueryString query,
HttpHeaders headers,
InputStream body,
long contentLength) |
| Modifier and Type | Method and Description |
|---|---|
InputStream |
getBody() |
HttpHeaders |
getHeaders() |
HttpMethod |
getMethod() |
QueryString |
getQueryString() |
URI |
getResourceUrl()
Returns the request target resource's Uniform Resource Locator location without a query string.
|
void |
setBody(InputStream body,
long length) |
void |
setHeaders(HttpHeaders headers) |
void |
setQueryString(QueryString queryString) |
hasBodyclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waithasBodypublic DefaultRequest(HttpMethod method, String href)
public DefaultRequest(HttpMethod method, String href, QueryString query)
public DefaultRequest(HttpMethod method, String href, QueryString query, HttpHeaders headers, InputStream body, long contentLength)
public HttpMethod getMethod()
public URI getResourceUrl()
RequestqueryString property.
This URI can be thought of the request fully qualified URL before any question mark indicating query parameters,
e.g. the parts in bold only:
https://some.host.com/some/resource/path/here?some=param&another=param.
Any potential question mark itself and anything after it are not included.getResourceUrl in interface Requestpublic HttpHeaders getHeaders()
getHeaders in interface HttpMessagepublic void setHeaders(HttpHeaders headers)
setHeaders in interface HttpMessagepublic QueryString getQueryString()
getQueryString in interface Requestpublic void setQueryString(QueryString queryString)
setQueryString in interface Requestpublic InputStream getBody()
getBody in interface HttpMessagepublic void setBody(InputStream body, long length)
Copyright © 2012–2014. All rights reserved.