org.apache.cocoon.environment.wrapper
Class AbstractRequestWrapper

java.lang.Object
  extended byorg.apache.cocoon.environment.impl.AbstractRequest
      extended byorg.apache.cocoon.environment.wrapper.AbstractRequestWrapper
All Implemented Interfaces:
HttpServletRequest, org.apache.cocoon.environment.Request, ServletRequest, org.apache.cocoon.environment.ValueHolder
Direct Known Subclasses:
RequestWrapper

public abstract class AbstractRequestWrapper
extends org.apache.cocoon.environment.impl.AbstractRequest

This is a wrapper class for the Request object. It just forwards every methods. It is the base class for all wrapper implementations.

Since:
2.2
Version:
$Id: AbstractRequestWrapper.html 1304280 2012-03-23 11:18:01Z ilgrosso $

Field Summary
protected  org.apache.cocoon.environment.Request req
          The real Request object
 
Fields inherited from interface org.apache.cocoon.environment.Request
GLOBAL_SCOPE, REQUEST_SCOPE
 
Fields inherited from interface javax.servlet.http.HttpServletRequest
BASIC_AUTH, CLIENT_CERT_AUTH, DIGEST_AUTH, FORM_AUTH
 
Constructor Summary
AbstractRequestWrapper(org.apache.cocoon.environment.Request request)
          Constructor
 
Method Summary
 Object get(String name)
           
 Object getAttribute(String name)
           
 Enumeration getAttributeNames()
           
 String getAuthType()
           
 String getCharacterEncoding()
           
 Map getCocoonCookieMap()
           
 org.apache.cocoon.environment.Cookie[] getCocoonCookies()
           
 org.apache.cocoon.environment.Session getCocoonSession()
           
 org.apache.cocoon.environment.Session getCocoonSession(boolean create)
           
 int getContentLength()
           
 String getContentType()
           
 String getContextPath()
           
 Map getCookieMap()
           
 Cookie[] getCookies()
           
 long getDateHeader(String name)
           
 String getHeader(String name)
           
 Enumeration getHeaderNames()
           
 Enumeration getHeaders(String name)
           
 ServletInputStream getInputStream()
           
 int getIntHeader(String name)
           
 String getLocalAddr()
           
 Object getLocalAttribute(String name)
           
 Enumeration getLocalAttributeNames()
           
 Locale getLocale()
           
 Enumeration getLocales()
           
 String getLocalName()
           
 int getLocalPort()
           
 String getMethod()
           
 String getParameter(String name)
           
 Map getParameterMap()
           
 Enumeration getParameterNames()
           
 String[] getParameterValues(String name)
           
 String getPathInfo()
           
 String getPathTranslated()
           
 String getProtocol()
           
 String getQueryString()
           
 BufferedReader getReader()
           
 String getRealPath(String path)
           
 String getRemoteAddr()
           
 String getRemoteHost()
           
 int getRemotePort()
           
 String getRemoteUser()
           
 RequestDispatcher getRequestDispatcher(String path)
           
 String getRequestedSessionId()
           
 String getRequestURI()
           
 StringBuffer getRequestURL()
           
 String getScheme()
           
 String getServerName()
           
 int getServerPort()
           
 String getServletPath()
           
 HttpSession getSession()
           
 HttpSession getSession(boolean create)
           
 String getSitemapPath()
           
 String getSitemapURI()
           
 String getSitemapURIPrefix()
           
 Principal getUserPrincipal()
           
 boolean isRequestedSessionIdFromCookie()
           
 boolean isRequestedSessionIdFromUrl()
           
 boolean isRequestedSessionIdFromURL()
           
 boolean isRequestedSessionIdValid()
           
 boolean isSecure()
           
 boolean isUserInRole(String role)
           
 void removeAttribute(String name)
           
 void removeLocalAttribute(String name)
           
 Object searchAttribute(String name)
           
 void setAttribute(String name, Object o)
           
 void setCharacterEncoding(String enc)
           
 void setLocalAttribute(String name, Object o)
           
 
Methods inherited from class org.apache.cocoon.environment.impl.AbstractRequest
getAttributes, getHeaders, getParameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

req

protected final org.apache.cocoon.environment.Request req
The real Request object

Constructor Detail

AbstractRequestWrapper

public AbstractRequestWrapper(org.apache.cocoon.environment.Request request)
Constructor

Parameters:
request - The Request being wrapped.
Method Detail

get

public Object get(String name)

getAttribute

public Object getAttribute(String name)

getAttributeNames

public Enumeration getAttributeNames()

getLocalAttribute

public Object getLocalAttribute(String name)

getLocalAttributeNames

public Enumeration getLocalAttributeNames()

removeLocalAttribute

public void removeLocalAttribute(String name)

setLocalAttribute

public void setLocalAttribute(String name,
                              Object o)

searchAttribute

public Object searchAttribute(String name)
See Also:
Request.searchAttribute(java.lang.String)

getCharacterEncoding

public String getCharacterEncoding()

setCharacterEncoding

public void setCharacterEncoding(String enc)
                          throws UnsupportedEncodingException
Throws:
UnsupportedEncodingException

getContentLength

public int getContentLength()

getContentType

public String getContentType()

getParameter

public String getParameter(String name)

getParameterNames

public Enumeration getParameterNames()

getParameterValues

public String[] getParameterValues(String name)

getProtocol

public String getProtocol()

getScheme

public String getScheme()

getServerName

public String getServerName()

getServerPort

public int getServerPort()

getRemoteAddr

public String getRemoteAddr()

getRemoteHost

public String getRemoteHost()

setAttribute

public void setAttribute(String name,
                         Object o)

removeAttribute

public void removeAttribute(String name)

getLocale

public Locale getLocale()

getLocales

public Enumeration getLocales()

isSecure

public boolean isSecure()

getCookies

public Cookie[] getCookies()

getCookieMap

public Map getCookieMap()

getDateHeader

public long getDateHeader(String name)

getHeader

public String getHeader(String name)

getHeaders

public Enumeration getHeaders(String name)

getHeaderNames

public Enumeration getHeaderNames()

getInputStream

public ServletInputStream getInputStream()
                                  throws IOException,
                                         UnsupportedOperationException
Throws:
IOException
UnsupportedOperationException

getMethod

public String getMethod()

getPathInfo

public String getPathInfo()

getPathTranslated

public String getPathTranslated()

getContextPath

public String getContextPath()

getQueryString

public String getQueryString()

getRemoteUser

public String getRemoteUser()

getRequestedSessionId

public String getRequestedSessionId()

getRequestURI

public String getRequestURI()

getSitemapURI

public String getSitemapURI()

getSitemapPath

public String getSitemapPath()

getServletPath

public String getServletPath()

getSession

public HttpSession getSession(boolean create)

getSession

public HttpSession getSession()

isRequestedSessionIdValid

public boolean isRequestedSessionIdValid()

isRequestedSessionIdFromCookie

public boolean isRequestedSessionIdFromCookie()

isRequestedSessionIdFromURL

public boolean isRequestedSessionIdFromURL()

getUserPrincipal

public Principal getUserPrincipal()

isUserInRole

public boolean isUserInRole(String role)

getAuthType

public String getAuthType()

getSitemapURIPrefix

public String getSitemapURIPrefix()
See Also:
Request.getSitemapURIPrefix()

getCocoonCookieMap

public Map getCocoonCookieMap()

getCocoonCookies

public org.apache.cocoon.environment.Cookie[] getCocoonCookies()

getCocoonSession

public org.apache.cocoon.environment.Session getCocoonSession(boolean create)

getCocoonSession

public org.apache.cocoon.environment.Session getCocoonSession()

getIntHeader

public int getIntHeader(String name)

getRequestURL

public StringBuffer getRequestURL()

isRequestedSessionIdFromUrl

public boolean isRequestedSessionIdFromUrl()

getLocalAddr

public String getLocalAddr()

getLocalName

public String getLocalName()

getLocalPort

public int getLocalPort()

getParameterMap

public Map getParameterMap()

getReader

public BufferedReader getReader()
                         throws IOException
Throws:
IOException

getRealPath

public String getRealPath(String path)

getRemotePort

public int getRemotePort()

getRequestDispatcher

public RequestDispatcher getRequestDispatcher(String path)


Copyright 1999-2008 The Apache Software Foundation. All Rights Reserved.