applications.webServer.httpPacketUtils
Class HttpRequest
- public class HttpRequest
Constructor Summary |
HttpRequest(InputStream httpRequestInputStream) |
body
private String body
EXPECTED_REQUEST_LINE_TOKEN_COUNT
private final static int EXPECTED_REQUEST_LINE_TOKEN_COUNT
headerFields
protected Hashtable headerFields
httpVersion
private String httpVersion
isWellFormed
private boolean isWellFormed
Log
static Category Log
method
private String method
parameterString
private String parameterString
requestUri
private String requestUri
HttpRequest
public HttpRequest(InputStream httpRequestInputStream)
getBody
public String getBody()
getHttpVersion
public String getHttpVersion()
getIsWellFormed
public boolean getIsWellFormed()
getMethod
public String getMethod()
getParameterString
public String getParameterString()
getRequestUri
public String getRequestUri()
parseHttpRequest
protected void parseHttpRequest(InputStream httpRequestInputStream)
parseRequestBody
protected void parseRequestBody(BufferedReader httpRequestBufferedReader)
parseRequestHeaderFields
protected void parseRequestHeaderFields(BufferedReader httpRequestBufferedReader)
-
Request Header Fields
All acceptable header fields are currently parsed and stored.
Acceptable request header fields are:
- Accept
- Accept-Charset
- Accept-Encoding
- Accept-Language
- Authorization
- Expect
- From
- Host
- If-Match
- If-Modified-Since
- If-None-Match
- If-Range
- If-Unmodified-Since
- Max-Forwards
- Proxy-Authorization
- Range
- Referer
- TE
- User-Agent
The following general header fields are also acceptable: - Cache-Control
- Connection
- Date
- Pragma
- Trailer
- Transfer-Encoding
- Upgrade
- Via
- Warning
The following entity header fields are also acceptable: - Allow
- Content-Encoding
- Content-Language
- Content-Length
- Content-Location
- Content-MD5
- Content-Range
- Content-Type
- Expires
- Last-Modified
Finally, entity header fields allow an extensible header field in the form: field-name ":" [ field-value ]
parseRequestLine
protected void parseRequestLine(BufferedReader httpRequestBufferedReader)
parseRequestUriWithParameters
protected void parseRequestUriWithParameters(String requestUriWithParameters)
printDebugInfo
public void printDebugInfo()