com.liferay.faces.bridge.filter
Class HttpServletRequestAdapter
java.lang.Object
javax.portlet.filter.PortletRequestWrapper
com.liferay.faces.bridge.filter.HttpServletRequestAdapter
- All Implemented Interfaces:
- javax.portlet.PortletRequest, javax.servlet.http.HttpServletRequest, javax.servlet.ServletRequest
- Direct Known Subclasses:
- BridgeAfterViewContentRequest
public class HttpServletRequestAdapter
- extends javax.portlet.filter.PortletRequestWrapper
- implements javax.servlet.http.HttpServletRequest
This class provides an HttpServletRequest adapter/wrapper around the current PortletRequest. Typical
usage is to hack-around Servlet-API dependencies in JSF implementations.
- Author:
- Neil Griffin
| Nested classes/interfaces inherited from interface javax.portlet.PortletRequest |
javax.portlet.PortletRequest.P3PUserInfos |
| Fields inherited from interface javax.servlet.http.HttpServletRequest |
BASIC_AUTH, CLIENT_CERT_AUTH, DIGEST_AUTH, FORM_AUTH |
| Fields inherited from interface javax.portlet.PortletRequest |
ACTION_PHASE, ACTION_SCOPE_ID, BASIC_AUTH, CCPP_PROFILE, CLIENT_CERT_AUTH, DIGEST_AUTH, EVENT_PHASE, FORM_AUTH, LIFECYCLE_PHASE, RENDER_HEADERS, RENDER_MARKUP, RENDER_PART, RENDER_PHASE, RESOURCE_PHASE, USER_INFO |
| Methods inherited from class javax.portlet.filter.PortletRequestWrapper |
getPortalContext, getPortletMode, getPortletSession, getPortletSession, getPreferences, getPrivateParameterMap, getProperties, getProperty, getPropertyNames, getPublicParameterMap, getRequest, getResponseContentType, getResponseContentTypes, getWindowID, getWindowState, isPortletModeAllowed, isWindowStateAllowed, setRequest |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
HttpServletRequestAdapter
public HttpServletRequestAdapter(javax.portlet.PortletRequest portletRequest)
removeAttribute
public void removeAttribute(String name)
- Specified by:
removeAttribute in interface javax.portlet.PortletRequest- Specified by:
removeAttribute in interface javax.servlet.ServletRequest- Overrides:
removeAttribute in class javax.portlet.filter.PortletRequestWrapper
getAttribute
public Object getAttribute(String name)
- Specified by:
getAttribute in interface javax.portlet.PortletRequest- Specified by:
getAttribute in interface javax.servlet.ServletRequest- Overrides:
getAttribute in class javax.portlet.filter.PortletRequestWrapper
setAttribute
public void setAttribute(String name,
Object value)
- Specified by:
setAttribute in interface javax.portlet.PortletRequest- Specified by:
setAttribute in interface javax.servlet.ServletRequest- Overrides:
setAttribute in class javax.portlet.filter.PortletRequestWrapper
getAttributeNames
public Enumeration<String> getAttributeNames()
- Specified by:
getAttributeNames in interface javax.portlet.PortletRequest- Specified by:
getAttributeNames in interface javax.servlet.ServletRequest- Overrides:
getAttributeNames in class javax.portlet.filter.PortletRequestWrapper
getAuthType
public String getAuthType()
- Specified by:
getAuthType in interface javax.portlet.PortletRequest- Specified by:
getAuthType in interface javax.servlet.http.HttpServletRequest- Overrides:
getAuthType in class javax.portlet.filter.PortletRequestWrapper
getCharacterEncoding
public String getCharacterEncoding()
- Specified by:
getCharacterEncoding in interface javax.servlet.ServletRequest
setCharacterEncoding
public void setCharacterEncoding(String enc)
throws UnsupportedEncodingException
- Specified by:
setCharacterEncoding in interface javax.servlet.ServletRequest
- Throws:
UnsupportedEncodingException
getContentLength
public int getContentLength()
- Specified by:
getContentLength in interface javax.servlet.ServletRequest
getContentType
public String getContentType()
- Specified by:
getContentType in interface javax.servlet.ServletRequest
getContextPath
public String getContextPath()
- Specified by:
getContextPath in interface javax.portlet.PortletRequest- Specified by:
getContextPath in interface javax.servlet.http.HttpServletRequest- Overrides:
getContextPath in class javax.portlet.filter.PortletRequestWrapper
getCookies
public javax.servlet.http.Cookie[] getCookies()
- Specified by:
getCookies in interface javax.portlet.PortletRequest- Specified by:
getCookies in interface javax.servlet.http.HttpServletRequest- Overrides:
getCookies in class javax.portlet.filter.PortletRequestWrapper
isRequestedSessionIdValid
public boolean isRequestedSessionIdValid()
- Specified by:
isRequestedSessionIdValid in interface javax.portlet.PortletRequest- Specified by:
isRequestedSessionIdValid in interface javax.servlet.http.HttpServletRequest- Overrides:
isRequestedSessionIdValid in class javax.portlet.filter.PortletRequestWrapper
getDateHeader
public long getDateHeader(String name)
- Specified by:
getDateHeader in interface javax.servlet.http.HttpServletRequest
isRequestedSessionIdFromCookie
public boolean isRequestedSessionIdFromCookie()
- Specified by:
isRequestedSessionIdFromCookie in interface javax.servlet.http.HttpServletRequest
isSecure
public boolean isSecure()
- Specified by:
isSecure in interface javax.portlet.PortletRequest- Specified by:
isSecure in interface javax.servlet.ServletRequest- Overrides:
isSecure in class javax.portlet.filter.PortletRequestWrapper
isUserInRole
public boolean isUserInRole(String role)
- Specified by:
isUserInRole in interface javax.portlet.PortletRequest- Specified by:
isUserInRole in interface javax.servlet.http.HttpServletRequest- Overrides:
isUserInRole in class javax.portlet.filter.PortletRequestWrapper
getHeader
public String getHeader(String name)
- Specified by:
getHeader in interface javax.servlet.http.HttpServletRequest
getHeaderNames
public Enumeration<String> getHeaderNames()
- Specified by:
getHeaderNames in interface javax.servlet.http.HttpServletRequest
getHeaders
public Enumeration<String> getHeaders(String name)
- Specified by:
getHeaders in interface javax.servlet.http.HttpServletRequest
getInputStream
public javax.servlet.ServletInputStream getInputStream()
throws IOException
- Specified by:
getInputStream in interface javax.servlet.ServletRequest
- Throws:
IOException
getIntHeader
public int getIntHeader(String arg0)
- Specified by:
getIntHeader in interface javax.servlet.http.HttpServletRequest
isRequestedSessionIdFromURL
public boolean isRequestedSessionIdFromURL()
- Specified by:
isRequestedSessionIdFromURL in interface javax.servlet.http.HttpServletRequest
isRequestedSessionIdFromUrl
public boolean isRequestedSessionIdFromUrl()
- Specified by:
isRequestedSessionIdFromUrl in interface javax.servlet.http.HttpServletRequest
getLocalAddr
public String getLocalAddr()
- Specified by:
getLocalAddr in interface javax.servlet.ServletRequest
getLocale
public Locale getLocale()
- Specified by:
getLocale in interface javax.portlet.PortletRequest- Specified by:
getLocale in interface javax.servlet.ServletRequest- Overrides:
getLocale in class javax.portlet.filter.PortletRequestWrapper
getLocales
public Enumeration<Locale> getLocales()
- Specified by:
getLocales in interface javax.portlet.PortletRequest- Specified by:
getLocales in interface javax.servlet.ServletRequest- Overrides:
getLocales in class javax.portlet.filter.PortletRequestWrapper
getLocalName
public String getLocalName()
- Specified by:
getLocalName in interface javax.servlet.ServletRequest
getLocalPort
public int getLocalPort()
- Specified by:
getLocalPort in interface javax.servlet.ServletRequest
getMethod
public String getMethod()
- Specified by:
getMethod in interface javax.servlet.http.HttpServletRequest
getParameter
public String getParameter(String name)
- Specified by:
getParameter in interface javax.portlet.PortletRequest- Specified by:
getParameter in interface javax.servlet.ServletRequest- Overrides:
getParameter in class javax.portlet.filter.PortletRequestWrapper
getParameterMap
public Map<String,String[]> getParameterMap()
- Specified by:
getParameterMap in interface javax.portlet.PortletRequest- Specified by:
getParameterMap in interface javax.servlet.ServletRequest- Overrides:
getParameterMap in class javax.portlet.filter.PortletRequestWrapper
getParameterNames
public Enumeration<String> getParameterNames()
- Specified by:
getParameterNames in interface javax.portlet.PortletRequest- Specified by:
getParameterNames in interface javax.servlet.ServletRequest- Overrides:
getParameterNames in class javax.portlet.filter.PortletRequestWrapper
getParameterValues
public String[] getParameterValues(String name)
- Specified by:
getParameterValues in interface javax.portlet.PortletRequest- Specified by:
getParameterValues in interface javax.servlet.ServletRequest- Overrides:
getParameterValues in class javax.portlet.filter.PortletRequestWrapper
getPathInfo
public String getPathInfo()
- Specified by:
getPathInfo in interface javax.servlet.http.HttpServletRequest
getPathTranslated
public String getPathTranslated()
- Specified by:
getPathTranslated in interface javax.servlet.http.HttpServletRequest
getProtocol
public String getProtocol()
- Specified by:
getProtocol in interface javax.servlet.ServletRequest
getQueryString
public String getQueryString()
- Specified by:
getQueryString in interface javax.servlet.http.HttpServletRequest
getReader
public BufferedReader getReader()
throws IOException
- Specified by:
getReader in interface javax.servlet.ServletRequest
- Throws:
IOException
getRealPath
public String getRealPath(String path)
- Specified by:
getRealPath in interface javax.servlet.ServletRequest
getRemoteAddr
public String getRemoteAddr()
- Specified by:
getRemoteAddr in interface javax.servlet.ServletRequest
getRemoteHost
public String getRemoteHost()
- Specified by:
getRemoteHost in interface javax.servlet.ServletRequest
getRemotePort
public int getRemotePort()
- Specified by:
getRemotePort in interface javax.servlet.ServletRequest
getRemoteUser
public String getRemoteUser()
- Specified by:
getRemoteUser in interface javax.portlet.PortletRequest- Specified by:
getRemoteUser in interface javax.servlet.http.HttpServletRequest- Overrides:
getRemoteUser in class javax.portlet.filter.PortletRequestWrapper
getRequestDispatcher
public javax.servlet.RequestDispatcher getRequestDispatcher(String path)
- Specified by:
getRequestDispatcher in interface javax.servlet.ServletRequest
getRequestedSessionId
public String getRequestedSessionId()
- Specified by:
getRequestedSessionId in interface javax.portlet.PortletRequest- Specified by:
getRequestedSessionId in interface javax.servlet.http.HttpServletRequest- Overrides:
getRequestedSessionId in class javax.portlet.filter.PortletRequestWrapper
getRequestURI
public String getRequestURI()
- Specified by:
getRequestURI in interface javax.servlet.http.HttpServletRequest
getRequestURL
public StringBuffer getRequestURL()
- Specified by:
getRequestURL in interface javax.servlet.http.HttpServletRequest
getScheme
public String getScheme()
- Specified by:
getScheme in interface javax.portlet.PortletRequest- Specified by:
getScheme in interface javax.servlet.ServletRequest- Overrides:
getScheme in class javax.portlet.filter.PortletRequestWrapper
getServerName
public String getServerName()
- Specified by:
getServerName in interface javax.portlet.PortletRequest- Specified by:
getServerName in interface javax.servlet.ServletRequest- Overrides:
getServerName in class javax.portlet.filter.PortletRequestWrapper
getServerPort
public int getServerPort()
- Specified by:
getServerPort in interface javax.portlet.PortletRequest- Specified by:
getServerPort in interface javax.servlet.ServletRequest- Overrides:
getServerPort in class javax.portlet.filter.PortletRequestWrapper
getServletPath
public String getServletPath()
- Specified by:
getServletPath in interface javax.servlet.http.HttpServletRequest
getSession
public javax.servlet.http.HttpSession getSession()
- Specified by:
getSession in interface javax.servlet.http.HttpServletRequest
getSession
public javax.servlet.http.HttpSession getSession(boolean create)
- Specified by:
getSession in interface javax.servlet.http.HttpServletRequest
getUserPrincipal
public Principal getUserPrincipal()
- Specified by:
getUserPrincipal in interface javax.portlet.PortletRequest- Specified by:
getUserPrincipal in interface javax.servlet.http.HttpServletRequest- Overrides:
getUserPrincipal in class javax.portlet.filter.PortletRequestWrapper
getWrapped
public javax.portlet.PortletRequest getWrapped()
Copyright © 2014 Liferay, Inc.. All Rights Reserved.