|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object | +--dfischer.femtowebserver.httpd.HttpRequest
Allows Weblets and SSSIs to access the HTTP request data (browser request).
More information about the HTTP protocol is available at http://www.w3.org
HttpdWebletInterface,
HttpdSssiInterface,
HttpUploadFile| Method Summary | |
void |
dump()
Dumps the http request to stdout. |
java.lang.String |
getBasicAuthorizationPassword()
Returns the (basic) authorization password, which has been set by the agent (browser). |
java.lang.String |
getBasicAuthorizationUsername()
Returns the (basic) authorization username, which has been set by the agent (browser). |
byte[] |
getContent()
Returns the content data of the request. |
java.lang.String |
getContentSubtype()
Returns the MIME subtype of the request content data, if this information has been set by the agent (browser). |
java.lang.String |
getContentType()
Returns the MIME type of the request content data, if this information has been set by the agent (browser). |
java.lang.String[] |
getHeader()
Returns the whole HTTP request header. |
java.lang.String |
getHeaderField(java.lang.String headerFieldName)
Returns the value of a header field name. |
java.lang.String[] |
getHeaderFieldNames()
Returns a list of all request header field names (header line 1..n-1). |
java.lang.String |
getHttpProtocol()
Returns the HTTP protocol version ("HTTP/1.0", "HTTP/1.1" ...) of the agent (browser). |
java.lang.String |
getMethod()
Returns the HTTP request method ("GET", "POST" ...). |
java.lang.String |
getParameter(java.lang.String parameterName)
Returns the value of a request parameter. |
java.lang.String |
getParameter(java.lang.String parameterName,
boolean asRawValue)
Returns the value of a request parameter. |
int |
getParameterAsInt(java.lang.String parameterName)
Returns the value of a request parameter as int number. |
java.lang.String[] |
getParameterNames()
Returns a list of all names of the request parameters, nevertheless if there is a "GET" or a "POST" request. |
java.lang.String |
getProtocol()
Returns the request network-protocol. |
java.lang.String |
getQueryString()
Returns all request parameter names and values. |
java.lang.String |
getRemoteAddress()
Returns the TCP/IP remote address of the agent (browser). |
java.lang.String |
getRequest()
Returns the request file with the full path. |
java.lang.String |
getRequestFile()
Returns the request file without any path. |
java.lang.String |
getRequestPath()
Returns the path to the request file (without the request file itself). |
HttpUploadFile |
getUploadFile(java.lang.String parameterName)
Returns an uploaded file with its data, selected by the HTML parameter name. |
HttpUploadFile[] |
getUploadFiles()
Returns all uploaded files. |
java.lang.String |
getURI()
Returns the request URI. |
java.lang.String |
getUserAgent()
Returns the browser product name and version (if any). |
java.lang.String |
getVirtualHost()
Returns the name of the TCP/IP host to which the agent (browser) has made the request. |
int |
getVirtualPort()
Returns the non-standard port number to which the agent (browser) has made the request. |
boolean |
hasBasicAuthorization()
Checks if a base64 (basic) authorization has been set by the agent (browser). |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
public java.lang.String getRemoteAddress()
public java.lang.String[] getHeader()
getHeaderFieldNames(),
getHeaderField(java.lang.String)public java.lang.String[] getHeaderFieldNames()
getHeaderField(java.lang.String),
getHeader()public java.lang.String getHeaderField(java.lang.String headerFieldName)
headerFieldName - name of the header field (not upper-/lower-case sensitive).getHeaderFieldNames(),
getHeader()public java.lang.String getMethod()
public java.lang.String getURI()
getRequest(),
getParameter(java.lang.String)public java.lang.String getProtocol()
public java.lang.String getHttpProtocol()
public java.lang.String getUserAgent()
public java.lang.String getVirtualHost()
HttpdProperties.getServerName()public int getVirtualPort()
HttpdProperties.getServerPort()public java.lang.String getContentType()
getContentSubtype(),
getContent()public java.lang.String getContentSubtype()
getContentType()public byte[] getContent()
getParameterNames(),
getParameter(java.lang.String)public java.lang.String getQueryString()
getParameterNames(),
getParameter(java.lang.String)public java.lang.String getRequestPath()
getRequestFile()public java.lang.String getRequestFile()
getRequestPath()public java.lang.String getRequest()
getRequestPath(),
getRequestFile(),
getURI()public java.lang.String[] getParameterNames()
getParameter(java.lang.String),
getParameterAsInt(java.lang.String)public java.lang.String getParameter(java.lang.String parameterName)
parameterName - the name of the request parametergetParameter(String, boolean),
getParameterNames(),
getParameterAsInt(java.lang.String)
public java.lang.String getParameter(java.lang.String parameterName,
boolean asRawValue)
parameterName - the name of the request parameterasRawValue - if true, don't decode the value from the MIME "x-www-form-urlencoded" formatgetParameter(String),
getParameterNames(),
getParameterAsInt(java.lang.String)public int getParameterAsInt(java.lang.String parameterName)
parameterName - the name of the request parametergetParameterNames(),
getParameter(java.lang.String)public HttpUploadFile getUploadFile(java.lang.String parameterName)
parameterName - HTML parameter namegetUploadFiles()public HttpUploadFile[] getUploadFiles()
getUploadFile(java.lang.String)public boolean hasBasicAuthorization()
getBasicAuthorizationUsername(),
getBasicAuthorizationPassword()public java.lang.String getBasicAuthorizationUsername()
getBasicAuthorizationPassword(),
hasBasicAuthorization()public java.lang.String getBasicAuthorizationPassword()
getBasicAuthorizationUsername(),
hasBasicAuthorization()public void dump()
Stdout
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||