public class HttpRequest extends HttpMessage
Modifier and Type | Field and Description |
---|---|
private String |
method |
static String |
METHOD_CONNECT
the CONNECT method
|
static String |
METHOD_DELETE
the DELETE method
|
static String |
METHOD_GET
the GET method
|
static String |
METHOD_HEAD
the POST method
|
static String |
METHOD_M_SEARCH
the M-SEARCH method
|
static String |
METHOD_NOTIFY
the NOTIFY method
|
static String |
METHOD_OPTIONS
the OPTIONS method
|
static String |
METHOD_POST
the POST method
|
static String |
METHOD_PUT
the PUT method
|
static String |
METHOD_TRACE
the TRACE method
|
private String |
uri |
CHAR_FILTER_BLACKLIST_COMMA_OR_SEMICOLON, CHAR_FILTER_WHITELIST_COMMA_OR_SEMICOLON, CRLF, HEADER_ATTRIBUTE_MAX_AGE, HEADER_PROPERTY_CACHE_CONTROL, HEADER_PROPERTY_CONTENT_ENCODING, HEADER_PROPERTY_CONTENT_LENGTH, HEADER_PROPERTY_CONTENT_TYPE, HEADER_PROPERTY_DATE, HEADER_PROPERTY_EXPIRES, HEADER_PROPERTY_FROM, HEADER_PROPERTY_HOST, HEADER_PROPERTY_IF_MODIFIED_SINCE, HEADER_PROPERTY_LAST_MODIFIED, HEADER_PROPERTY_LOCATION, HEADER_PROPERTY_PRAGMA, HEADER_PROPERTY_REFERER, HEADER_PROPERTY_SERVER, HEADER_PROPERTY_USER_AGENT, HEADER_PROPERTY_WWW_AUTHENTICATE, VERSION_0_9, VERSION_1_0, VERSION_1_1, VERSION_PREFIX
Constructor and Description |
---|
HttpRequest()
The constructor.
|
Modifier and Type | Method and Description |
---|---|
String |
getMethod()
This method gets the HTTP method to use.
|
String |
getUri()
This method gets the requested URI (e.g.
|
void |
setMethod(String httpMethod)
This method sets the HTTP
method to use. |
void |
setUri(String requestUri)
This method sets the requested URI.
|
protected void |
writeFirstLine(StringBuffer buffer)
This method writes the first line (request-line or status-line) of the HTTP message.
|
appendHeaderProperty, appendHeaderProperty, createHeaderNameHash, getCacheControlMaxAge, getContentEncoding, getContentLength, getContentType, getDate, getHeaderProperty, getHeaderPropertyAttribute, getVersion, serialize, setCacheControlMaxAge, setContentEncoding, setContentLength, setContentType, setDate, setHeaderProperty, setHeaderPropertyAttribute, setVersion, toString
public static final String METHOD_GET
public static final String METHOD_HEAD
public static final String METHOD_POST
public static final String METHOD_PUT
public static final String METHOD_DELETE
public static final String METHOD_OPTIONS
public static final String METHOD_TRACE
public static final String METHOD_CONNECT
public static final String METHOD_NOTIFY
public static final String METHOD_M_SEARCH
private String method
private String uri
public String getMethod()
public void setMethod(String httpMethod)
method
to use.httpMethod
- the HTTP method to set.public String getUri()
public void setUri(String requestUri)
requestUri
- the uri to setgetUri()
protected void writeFirstLine(StringBuffer buffer)
HttpMessage
writeFirstLine
in class HttpMessage
buffer
- is the string-buffer where to append the first line.Copyright © 2001–2016 mmm-Team. All rights reserved.