All Packages Class Hierarchy This Package Previous Next Index
Interface Acme.Serve.servlet.http.HttpServletRequest
- public interface HttpServletRequest
- extends ServletRequest
This interface represents an HTTP request.
This is taken from JavaSoft's Servlet API documentation.
Fetch the software.
Fetch the entire Acme package.
- See Also:
- Servlet
-
getAuthType()
- Returns the authentication scheme of the request, or null if none.
-
getCookies()
- Gets the array of cookies found in this request.
-
getDateHeader(String, long)
- Returns the value of a date header field.
-
getHeader(String)
- Returns the value of a header field, or null if not known.
-
getHeaderNames()
- Returns an Enumeration of the header names.
-
getIntHeader(String, int)
- Returns the value of an integer header field.
-
getLongHeader(String, long)
- Returns the value of a long header field.
-
getMethod()
- Returns the method with which the request was made.
-
getPathInfo()
- Returns optional extra path information following the servlet path, but
immediately preceding the query string.
-
getPathTranslated()
- Returns extra path information translated to a real path.
-
getQueryString()
- Returns the query string part of the servlet URI, or null if none.
-
getRemoteUser()
- Returns the name of the user making this request, or null if not known.
-
getRequestedSessionId()
- Gets the session id specified with this request.
-
getRequestURI()
- Returns the full request URI.
-
getServletPath()
- Returns the part of the request URI that referred to the servlet being
invoked.
-
getSession(boolean)
- Gets the current valid session associated with this request, if
create is false or, if necessary, creates a new session for the
request, if create is true.
-
isRequestedSessionIdFromCookie()
- Checks whether the session id specified by this request came in as
a cookie.
-
isRequestedSessionIdFromUrl()
- Checks whether the session id specified by this request came in as
part of the URL.
-
isRequestedSessionIdValid()
- Checks whether this request is associated with a session that is
valid in the current session context.
getCookies
public abstract Cookie[] getCookies()
- Gets the array of cookies found in this request.
getMethod
public abstract String getMethod()
- Returns the method with which the request was made. This can be "GET",
"HEAD", "POST", or an extension method.
Same as the CGI variable REQUEST_METHOD.
getRequestURI
public abstract String getRequestURI()
- Returns the full request URI.
getServletPath
public abstract String getServletPath()
- Returns the part of the request URI that referred to the servlet being
invoked.
Analogous to the CGI variable SCRIPT_NAME.
getPathInfo
public abstract String getPathInfo()
- Returns optional extra path information following the servlet path, but
immediately preceding the query string. Returns null if not specified.
Same as the CGI variable PATH_INFO.
getPathTranslated
public abstract String getPathTranslated()
- Returns extra path information translated to a real path. Returns
null if no extra path information was specified.
Same as the CGI variable PATH_TRANSLATED.
getQueryString
public abstract String getQueryString()
- Returns the query string part of the servlet URI, or null if none.
Same as the CGI variable QUERY_STRING.
getRemoteUser
public abstract String getRemoteUser()
- Returns the name of the user making this request, or null if not known.
Same as the CGI variable REMOTE_USER.
getAuthType
public abstract String getAuthType()
- Returns the authentication scheme of the request, or null if none.
Same as the CGI variable AUTH_TYPE.
getHeader
public abstract String getHeader(String name)
- Returns the value of a header field, or null if not known.
Same as the information passed in the CGI variabled HTTP_*.
- Parameters:
- name - the header field name
getIntHeader
public abstract int getIntHeader(String name,
int def)
- Returns the value of an integer header field.
- Parameters:
- name - the header field name
- def - the integer value to return if header not found or invalid
getLongHeader
public abstract long getLongHeader(String name,
long def)
- Returns the value of a long header field.
- Parameters:
- name - the header field name
- def - the long value to return if header not found or invalid
getDateHeader
public abstract long getDateHeader(String name,
long def)
- Returns the value of a date header field.
- Parameters:
- name - the header field name
- def - the date value to return if header not found or invalid
getHeaderNames
public abstract Enumeration getHeaderNames()
- Returns an Enumeration of the header names.
getSession
public abstract HttpSession getSession(boolean create)
- Gets the current valid session associated with this request, if
create is false or, if necessary, creates a new session for the
request, if create is true.
Note: to ensure the session is properly maintained, the servlet
developer must call this method (at least once) before any output
is written to the response.
Additionally, application-writers need to be aware that newly
created sessions (that is, sessions for which HttpSession.isNew
returns true) do not have any application-specific state.
getRequestedSessionId
public abstract String getRequestedSessionId()
- Gets the session id specified with this request. This may differ
from the actual session id. For example, if the request specified
an id for an invalid session, then this will get a new session with
a new id.
isRequestedSessionIdValid
public abstract boolean isRequestedSessionIdValid()
- Checks whether this request is associated with a session that is
valid in the current session context. If it is not valid, the
requested session will never be returned from the getSession
method.
isRequestedSessionIdFromCookie
public abstract boolean isRequestedSessionIdFromCookie()
- Checks whether the session id specified by this request came in as
a cookie. (The requested session may not be one returned by the
getSession method.)
isRequestedSessionIdFromUrl
public abstract boolean isRequestedSessionIdFromUrl()
- Checks whether the session id specified by this request came in as
part of the URL. (The requested session may not be the one returned
by the getSession method.)
All Packages Class Hierarchy This Package Previous Next Index
ACME Java ACME Labs