|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jcs.utils.servlet.session.HttpServletRequestFacade
Session wrapper, to overide some methods. Servlet 2.3 has an easier way to do this.
Field Summary | |
private java.lang.String |
characterEncoding
|
private static DistSessionTracker |
dst
|
private MetaHttpSession |
ms
|
private javax.servlet.http.HttpServletRequest |
req
|
private javax.servlet.http.HttpServletResponse |
res
|
Constructor Summary | |
HttpServletRequestFacade(javax.servlet.http.HttpServletRequest req,
javax.servlet.http.HttpServletResponse res)
Needs some way to get cookies out, must pass res too! |
Method Summary | |
java.lang.Object |
getAttribute(java.lang.String name)
Gets the attribute attribute of the HttpServletRequestFacade object |
java.util.Enumeration |
getAttributeNames()
Gets the attributeNames attribute of the HttpServletRequestFacade object |
java.lang.String |
getAuthType()
Gets the authType attribute of the HttpServletRequestFacade object |
java.lang.String |
getCharacterEncoding()
Gets the characterEncoding attribute of the HttpServletRequestFacade object |
int |
getContentLength()
Gets the contentLength attribute of the HttpServletRequestFacade object |
java.lang.String |
getContentType()
Gets the contentType attribute of the HttpServletRequestFacade object |
java.lang.String |
getContextPath()
Gets the contextPath attribute of the HttpServletRequestFacade object |
javax.servlet.http.Cookie[] |
getCookies()
Gets the cookies attribute of the HttpServletRequestFacade object |
long |
getDateHeader(java.lang.String name)
Gets the dateHeader attribute of the HttpServletRequestFacade object |
java.lang.String |
getHeader(java.lang.String name)
Gets the header attribute of the HttpServletRequestFacade object |
java.util.Enumeration |
getHeaderNames()
Gets the headerNames attribute of the HttpServletRequestFacade object |
java.util.Enumeration |
getHeaders(java.lang.String name)
Gets the headers attribute of the HttpServletRequestFacade object |
javax.servlet.ServletInputStream |
getInputStream()
Gets the inputStream attribute of the HttpServletRequestFacade object |
int |
getIntHeader(java.lang.String name)
Gets the intHeader attribute of the HttpServletRequestFacade object |
java.util.Locale |
getLocale()
Gets the locale attribute of the HttpServletRequestFacade object |
java.util.Enumeration |
getLocales()
Gets the locales attribute of the HttpServletRequestFacade object |
java.lang.String |
getMethod()
Gets the method attribute of the HttpServletRequestFacade object |
java.lang.String |
getParameter(java.lang.String name)
Gets the parameter attribute of the HttpServletRequestFacade object |
java.util.Map |
getParameterMap()
The implementation of this method will remain somewhat expensive until Servlet API 2.3 is adopted. |
java.util.Enumeration |
getParameterNames()
Gets the parameterNames attribute of the HttpServletRequestFacade object |
java.lang.String[] |
getParameterValues(java.lang.String name)
Gets the parameterValues attribute of the HttpServletRequestFacade object |
java.lang.String |
getPathInfo()
Gets the pathInfo attribute of the HttpServletRequestFacade object |
java.lang.String |
getPathTranslated()
Gets the pathTranslated attribute of the HttpServletRequestFacade object |
java.lang.String |
getProtocol()
Gets the protocol attribute of the HttpServletRequestFacade object |
java.lang.String |
getQueryString()
Gets the queryString attribute of the HttpServletRequestFacade object |
java.io.BufferedReader |
getReader()
Gets the reader attribute of the HttpServletRequestFacade object |
java.lang.String |
getRealPath(java.lang.String path)
Gets the realPath attribute of the HttpServletRequestFacade object |
java.lang.String |
getRemoteAddr()
Gets the remoteAddr attribute of the HttpServletRequestFacade object |
java.lang.String |
getRemoteHost()
Gets the remoteHost attribute of the HttpServletRequestFacade object |
java.lang.String |
getRemoteUser()
Gets the remoteUser attribute of the HttpServletRequestFacade object |
javax.servlet.RequestDispatcher |
getRequestDispatcher(java.lang.String path)
Gets the requestDispatcher attribute of the HttpServletRequestFacade object |
java.lang.String |
getRequestedSessionId()
Gets the requestedSessionId attribute of the HttpServletRequestFacade object |
java.lang.String |
getRequestURI()
Gets the requestURI attribute of the HttpServletRequestFacade object |
java.lang.StringBuffer |
getRequestURL()
Gets the full request URL. |
java.lang.String |
getScheme()
Gets the scheme attribute of the HttpServletRequestFacade object |
java.lang.String |
getServerName()
Gets the serverName attribute of the HttpServletRequestFacade object |
int |
getServerPort()
Gets the serverPort attribute of the HttpServletRequestFacade object |
java.lang.String |
getServletPath()
Gets the servletPath attribute of the HttpServletRequestFacade object |
javax.servlet.http.HttpSession |
getSession()
Gets the session attribute of the HttpServletRequestFacade object |
javax.servlet.http.HttpSession |
getSession(boolean create)
Gets the session attribute of the HttpServletRequestFacade object |
java.lang.String |
getSessionId()
Gets the sessionId attribute of the HttpServletRequestFacade object |
java.security.Principal |
getUserPrincipal()
Gets the userPrincipal attribute of the HttpServletRequestFacade object |
boolean |
isRequestedSessionIdFromCookie()
Gets the requestedSessionIdFromCookie attribute of the HttpServletRequestFacade object |
boolean |
isRequestedSessionIdFromUrl()
Gets the requestedSessionIdFromUrl attribute of the HttpServletRequestFacade object |
boolean |
isRequestedSessionIdFromURL()
Gets the requestedSessionIdFromURL attribute of the HttpServletRequestFacade object |
boolean |
isRequestedSessionIdValid()
Gets the requestedSessionIdValid attribute of the HttpServletRequestFacade object |
boolean |
isSecure()
Gets the secure attribute of the HttpServletRequestFacade object |
boolean |
isUserInRole(java.lang.String role)
Gets the userInRole attribute of the HttpServletRequestFacade object |
void |
removeAttribute(java.lang.String name)
Description of the Method |
void |
setAttribute(java.lang.String key,
java.lang.Object o)
Sets the attribute attribute of the HttpServletRequestFacade object |
void |
setCharacterEncoding(java.lang.String enc)
Overrides the name of the character encoding used in the body of this request. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final transient DistSessionTracker dst
private final javax.servlet.http.HttpServletRequest req
private final javax.servlet.http.HttpServletResponse res
private MetaHttpSession ms
private java.lang.String characterEncoding
Constructor Detail |
public HttpServletRequestFacade(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse res)
req
- res
- Method Detail |
public java.lang.String getSessionId()
public javax.servlet.http.HttpSession getSession()
getSession
in interface javax.servlet.http.HttpServletRequest
public javax.servlet.http.HttpSession getSession(boolean create)
getSession
in interface javax.servlet.http.HttpServletRequest
public java.lang.Object getAttribute(java.lang.String name)
getAttribute
in interface javax.servlet.ServletRequest
public java.util.Enumeration getAttributeNames()
getAttributeNames
in interface javax.servlet.ServletRequest
public java.lang.String getCharacterEncoding()
getCharacterEncoding
in interface javax.servlet.ServletRequest
public void setCharacterEncoding(java.lang.String enc) throws java.io.UnsupportedEncodingException
getReader()
. NOTE: This method will
not modify the underlying request until Servlet API 2.3 is adopted.
enc
- The character encoding to be used
java.io.UnsupportedEncodingException
- If the specified encoding is not
supported.public int getContentLength()
getContentLength
in interface javax.servlet.ServletRequest
public java.lang.String getContentType()
getContentType
in interface javax.servlet.ServletRequest
public javax.servlet.ServletInputStream getInputStream() throws java.io.IOException
getInputStream
in interface javax.servlet.ServletRequest
java.io.IOException
public java.lang.String getParameter(java.lang.String name)
getParameter
in interface javax.servlet.ServletRequest
public java.util.Enumeration getParameterNames()
getParameterNames
in interface javax.servlet.ServletRequest
public java.lang.String[] getParameterValues(java.lang.String name)
getParameterValues
in interface javax.servlet.ServletRequest
public java.util.Map getParameterMap()
public java.lang.String getProtocol()
getProtocol
in interface javax.servlet.ServletRequest
public java.lang.String getScheme()
getScheme
in interface javax.servlet.ServletRequest
public java.lang.String getServerName()
getServerName
in interface javax.servlet.ServletRequest
public int getServerPort()
getServerPort
in interface javax.servlet.ServletRequest
public java.io.BufferedReader getReader() throws java.io.IOException
getReader
in interface javax.servlet.ServletRequest
java.io.IOException
public java.lang.String getRemoteAddr()
getRemoteAddr
in interface javax.servlet.ServletRequest
public java.lang.String getRemoteHost()
getRemoteHost
in interface javax.servlet.ServletRequest
public void setAttribute(java.lang.String key, java.lang.Object o)
setAttribute
in interface javax.servlet.ServletRequest
key
- The new attribute valueo
- The new attribute valuepublic void removeAttribute(java.lang.String name)
removeAttribute
in interface javax.servlet.ServletRequest
public java.util.Locale getLocale()
getLocale
in interface javax.servlet.ServletRequest
public java.util.Enumeration getLocales()
getLocales
in interface javax.servlet.ServletRequest
public boolean isSecure()
isSecure
in interface javax.servlet.ServletRequest
public javax.servlet.RequestDispatcher getRequestDispatcher(java.lang.String path)
getRequestDispatcher
in interface javax.servlet.ServletRequest
public java.lang.String getRealPath(java.lang.String path)
getRealPath
in interface javax.servlet.ServletRequest
public java.lang.String getAuthType()
getAuthType
in interface javax.servlet.http.HttpServletRequest
public javax.servlet.http.Cookie[] getCookies()
getCookies
in interface javax.servlet.http.HttpServletRequest
public long getDateHeader(java.lang.String name)
getDateHeader
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getHeader(java.lang.String name)
getHeader
in interface javax.servlet.http.HttpServletRequest
public java.util.Enumeration getHeaders(java.lang.String name)
getHeaders
in interface javax.servlet.http.HttpServletRequest
public java.util.Enumeration getHeaderNames()
getHeaderNames
in interface javax.servlet.http.HttpServletRequest
public int getIntHeader(java.lang.String name)
getIntHeader
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getMethod()
getMethod
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getPathInfo()
getPathInfo
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getPathTranslated()
getPathTranslated
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getContextPath()
getContextPath
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getQueryString()
getQueryString
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getRemoteUser()
getRemoteUser
in interface javax.servlet.http.HttpServletRequest
public boolean isUserInRole(java.lang.String role)
isUserInRole
in interface javax.servlet.http.HttpServletRequest
public java.security.Principal getUserPrincipal()
getUserPrincipal
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getRequestedSessionId()
getRequestedSessionId
in interface javax.servlet.http.HttpServletRequest
public java.lang.String getRequestURI()
getRequestURI
in interface javax.servlet.http.HttpServletRequest
public java.lang.StringBuffer getRequestURL()
public java.lang.String getServletPath()
getServletPath
in interface javax.servlet.http.HttpServletRequest
public boolean isRequestedSessionIdValid()
isRequestedSessionIdValid
in interface javax.servlet.http.HttpServletRequest
public boolean isRequestedSessionIdFromCookie()
isRequestedSessionIdFromCookie
in interface javax.servlet.http.HttpServletRequest
public boolean isRequestedSessionIdFromURL()
isRequestedSessionIdFromURL
in interface javax.servlet.http.HttpServletRequest
public boolean isRequestedSessionIdFromUrl()
isRequestedSessionIdFromUrl
in interface javax.servlet.http.HttpServletRequest
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |