All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface Acme.Serve.servlet.ServletRequest

public interface ServletRequest

Method Index

 o getAttribute(String)
Returns the value of the named attribute of the request, or null if the attribute does not exist.
 o getContentLength()
Returns the size of the request entity data, or -1 if not known.
 o getContentType()
Returns the MIME type of the request entity data, or null if not known.
 o getInputStream()
Returns an input stream for reading request data.
 o getParameter(String)
Returns a string containing the value of the specified parameter, or null if the parameter does not exist.
 o getParameterNames()
Returns the parameter names for this request.
 o getParameterValues(String)
Returns the values of the specified parameter for the request as an array of strings, or null if the named parameter does not exist.
 o getProtocol()
Returns the protocol and version of the request as a string of the form /..
 o getReader()
Returns a buffered reader for reading request data.
 o getRealPath(String)
Applies alias rules to the specified virtual path and returns the corresponding real path, or null if the translation can not be performed for any reason.
 o getRemoteAddr()
Returns the IP address of the agent that sent the request.
 o getRemoteHost()
Returns the fully qualified host name of the agent that sent the request.
 o getScheme()
Returns the scheme of the URL used in this request, for example "http", "https", or "ftp".
 o getServerName()
Returns the host name of the server as used in the part of the request URI.
 o getServerPort()
Returns the port number on which this request was received as used in the part of the request URI.

Methods

 o getContentLength
 public abstract int getContentLength()
Returns the size of the request entity data, or -1 if not known. Same as the CGI variable CONTENT_LENGTH.

 o getContentType
 public abstract String getContentType()
Returns the MIME type of the request entity data, or null if not known. Same as the CGI variable CONTENT_TYPE.

 o getProtocol
 public abstract String getProtocol()
Returns the protocol and version of the request as a string of the form /.. Same as the CGI variable SERVER_PROTOCOL.

 o getScheme
 public abstract String getScheme()
Returns the scheme of the URL used in this request, for example "http", "https", or "ftp". Different schemes have different rules for constructing URLs, as noted in RFC 1738. The URL used to create a request may be reconstructed using this scheme, the server name and port, and additional information such as URIs.

 o getServerName
 public abstract String getServerName()
Returns the host name of the server as used in the part of the request URI. Same as the CGI variable SERVER_NAME.

 o getServerPort
 public abstract int getServerPort()
Returns the port number on which this request was received as used in the part of the request URI. Same as the CGI variable SERVER_PORT.

 o getRemoteAddr
 public abstract String getRemoteAddr()
Returns the IP address of the agent that sent the request. Same as the CGI variable REMOTE_ADDR.

 o getRemoteHost
 public abstract String getRemoteHost()
Returns the fully qualified host name of the agent that sent the request. Same as the CGI variable REMOTE_HOST.

 o getRealPath
 public abstract String getRealPath(String path)
Applies alias rules to the specified virtual path and returns the corresponding real path, or null if the translation can not be performed for any reason. For example, an HTTP servlet would resolve the path using the virtual docroot, if virtual hosting is enabled, and with the default docroot otherwise. Calling this method with the string "/" as an argument returns the document root.

 o getInputStream
 public abstract ServletInputStream getInputStream() throws IOException
Returns an input stream for reading request data.

Throws: IllegalStateException
if getReader has already been called
Throws: IOException
on other I/O-related errors
 o getReader
 public abstract BufferedReader getReader()
Returns a buffered reader for reading request data.

Throws: UnsupportedEncodingException
if the character set encoding isn't supported
Throws: IllegalStateException
if getInputStream has already been called
Throws: IOException
on other I/O-related errors
 o getParameter
 public abstract String getParameter(String name)
Returns a string containing the value of the specified parameter, or null if the parameter does not exist.

 o getParameterValues
 public abstract String[] getParameterValues(String name)
Returns the values of the specified parameter for the request as an array of strings, or null if the named parameter does not exist.

 o getParameterNames
 public abstract Enumeration getParameterNames()
Returns the parameter names for this request.

 o getAttribute
 public abstract Object getAttribute(String name)
Returns the value of the named attribute of the request, or null if the attribute does not exist. This method allows access to request information not already provided by the other methods in this interface.


All Packages  Class Hierarchy  This Package  Previous  Next  Index

ACME Java  ACME Labs