java.lang.Object
javax.servlet.ServletRequestWrapper
javax.servlet.http.HttpServletRequestWrapper
com.meterware.servletunit.DispatchedRequestWrapper
- All Implemented Interfaces:
- javax.servlet.http.HttpServletRequest, javax.servlet.ServletRequest
- Direct Known Subclasses:
- ForwardRequestWrapper, IncludeRequestWrapper
- class DispatchedRequestWrapper
- extends javax.servlet.http.HttpServletRequestWrapper
This class represents a request dispatched via a RequestDispatcherImpl.
| Methods inherited from class javax.servlet.http.HttpServletRequestWrapper |
getAuthType, getContextPath, getCookies, getDateHeader, getHeader, getHeaderNames, getHeaders, getIntHeader, getMethod, getPathInfo, getPathTranslated, getQueryString, getRemoteUser, getRequestedSessionId, getRequestURI, getRequestURL, getServletPath, getSession, getSession, getUserPrincipal, isRequestedSessionIdFromCookie, isRequestedSessionIdFromUrl, isRequestedSessionIdFromURL, isRequestedSessionIdValid, isUserInRole |
| Methods inherited from class javax.servlet.ServletRequestWrapper |
getAttribute, getAttributeNames, getCharacterEncoding, getContentLength, getContentType, getInputStream, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getProtocol, getReader, getRealPath, getRemoteAddr, getRemoteHost, getRemotePort, getRequest, getRequestDispatcher, getScheme, getServerName, getServerPort, isSecure, removeAttribute, setAttribute, setCharacterEncoding, setRequest |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface javax.servlet.ServletRequest |
getAttribute, getAttributeNames, getCharacterEncoding, getContentLength, getContentType, getInputStream, getLocalAddr, getLocale, getLocales, getLocalName, getLocalPort, getProtocol, getReader, getRealPath, getRemoteAddr, getRemoteHost, getRemotePort, getRequestDispatcher, getScheme, getServerName, getServerPort, isSecure, removeAttribute, setAttribute, setCharacterEncoding |
_requestContext
private RequestContext _requestContext
- Request-specific information, including parameters and paths.
_baseRequest
private javax.servlet.http.HttpServletRequest _baseRequest
- The request being wrapped.
DispatchedRequestWrapper
DispatchedRequestWrapper(javax.servlet.http.HttpServletRequest baseRequest,
javax.servlet.RequestDispatcher dispatcher)
createIncludeRequestWrapper
static javax.servlet.http.HttpServletRequest createIncludeRequestWrapper(javax.servlet.http.HttpServletRequest request,
javax.servlet.RequestDispatcher dispatcher)
createForwardRequestWrapper
static javax.servlet.http.HttpServletRequest createForwardRequestWrapper(javax.servlet.http.HttpServletRequest request,
javax.servlet.RequestDispatcher dispatcher)
getBaseRequest
javax.servlet.http.HttpServletRequest getBaseRequest()
getParameter
public java.lang.String getParameter(java.lang.String s)
- Description copied from interface:
javax.servlet.ServletRequest
- Returns the value of a request parameter as a
String,
or null if the parameter does not exist. Request parameters
are extra information sent with the request. For HTTP servlets,
parameters are contained in the query string or posted form data.
You should only use this method when you are sure the
parameter has only one value. If the parameter might have
more than one value, use ServletRequest.getParameterValues(java.lang.String)>ServletRequest.getParameterValues(java.lang.String) 55 .
If you use this method with a multivalued
parameter, the value returned is equal to the first value
in the array returned by getParameterValues.
If the parameter data was sent in the request body, such as occurs
with an HTTP POST request, then reading the body directly via ServletRequest.getInputStream()>ServletRequest.getInputStream() 55 or ServletRequest.getReader()>ServletRequest.getReader() 55 can interfere
with the execution of this method.
getParameterNames
public java.util.Enumeration getParameterNames()
- Description copied from interface:
javax.servlet.ServletRequest
- Returns an
Enumeration of String
objects containing the names of the parameters contained
in this request. If the request has
no parameters, the method returns an
empty Enumeration.
getParameterValues
public java.lang.String[] getParameterValues(java.lang.String s)
- Description copied from interface:
javax.servlet.ServletRequest
- Returns an array of
String objects containing
all of the values the given request parameter has, or
null if the parameter does not exist.
If the parameter has a single value, the array has a length
of 1.
getParameterMap
public java.util.Map getParameterMap()
- Description copied from interface:
javax.servlet.ServletRequest
- Returns a java.util.Map of the parameters of this request.
Request parameters
are extra information sent with the request. For HTTP servlets,
parameters are contained in the query string or posted form data.