vmassol     01/08/19 08:27:49

  Modified:    cactus/src/framework/servlet23/org/apache/commons/cactus/server
                        HttpServletRequestWrapper.java
                        RequestDispatcherWrapper.java
                        ServletConfigWrapper.java
                        ServletContextWrapper.java
  Log:
  align with coding conventions
  
  Revision  Changes    Path
  1.5       +109 -101  
jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/HttpServletRequestWrapper.java
  
  Index: HttpServletRequestWrapper.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/HttpServletRequestWrapper.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- HttpServletRequestWrapper.java    2001/07/05 14:24:45     1.4
  +++ HttpServletRequestWrapper.java    2001/08/19 15:27:49     1.5
  @@ -74,25 +74,28 @@
    * <code>getRequestURI()</code> method or others alike) would be the URL of the
    * Cactus redirector servlet and not a URL that the test case want to simulate.
    *
  - * @version @version@
  + * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
  + *
  + * @version $Id: HttpServletRequestWrapper.java,v 1.5 2001/08/19 15:27:49 vmassol 
Exp $
    */
   public class HttpServletRequestWrapper implements HttpServletRequest
   {
       /**
        * The real HTTP request
        */
  -    private HttpServletRequest m_Request;
  +    private HttpServletRequest request;
   
       /**
        * The URL to simulate
        */
  -    private ServletURL m_URL;
  +    private ServletURL url;
   
       /**
        * The logger
        */
  -    private static Log m_Logger =
  -        LogService.getInstance().getLog(HttpServletRequestWrapper.class.getName());
  +    private static Log logger =
  +        LogService.getInstance().
  +        getLog(HttpServletRequestWrapper.class.getName());
   
       /**
        * Construct an <code>HttpServletRequest</code> instance that delegates
  @@ -103,54 +106,55 @@
        * @param theRequest the real HTTP request
        * @param theURL     the URL to simulate or <code>null</code> if none
        */
  -    public HttpServletRequestWrapper(HttpServletRequest theRequest, ServletURL 
theURL)
  +    public HttpServletRequestWrapper(HttpServletRequest theRequest,
  +        ServletURL theURL)
       {
  -        m_Request = theRequest;
  -        m_URL = theURL;
  +        this.request = theRequest;
  +        this.url = theURL;
       }
   
       public HttpServletRequest getOriginalRequest()
       {
  -        return m_Request;
  +        return this.request;
       }
   
       public boolean isUserInRole(String theRole)
       {
  -        return m_Request.isUserInRole(theRole);
  +        return this.request.isUserInRole(theRole);
       }
   
       public boolean isRequestedSessionIdValid()
       {
  -        return m_Request.isRequestedSessionIdValid();
  +        return this.request.isRequestedSessionIdValid();
       }
       public boolean isRequestedSessionIdFromUrl()
       {
  -        return m_Request.isRequestedSessionIdFromUrl();
  +        return this.request.isRequestedSessionIdFromUrl();
       }
   
       public boolean isRequestedSessionIdFromURL()
       {
  -        return m_Request.isRequestedSessionIdFromURL();
  +        return this.request.isRequestedSessionIdFromURL();
       }
   
       public boolean isRequestedSessionIdFromCookie()
       {
  -        return m_Request.isRequestedSessionIdFromCookie();
  +        return this.request.isRequestedSessionIdFromCookie();
       }
   
       public Principal getUserPrincipal()
       {
  -        return m_Request.getUserPrincipal();
  +        return this.request.getUserPrincipal();
       }
   
       public HttpSession getSession(boolean isCreate)
       {
  -        return m_Request.getSession(isCreate);
  +        return this.request.getSession(isCreate);
       }
   
       public HttpSession getSession()
       {
  -        return m_Request.getSession();
  +        return this.request.getSession();
       }
   
       /**
  @@ -159,27 +163,28 @@
        */
       public String getServletPath()
       {
  -        m_Logger.entry("getServletPath()");
  +        this.logger.entry("getServletPath()");
   
  -        String result = m_Request.getServletPath();
  +        String result = this.request.getServletPath();
   
  -        if (m_URL != null) {
  -            result = m_URL.getServletPath();
  -            m_Logger.debug("Using simulated servlet path : [" + result + "]");
  +        if (this.url != null) {
  +            result = this.url.getServletPath();
  +            this.logger.debug("Using simulated servlet path : [" + result +
  +                "]");
           }
   
  -        m_Logger.exit("getServletPath");
  +        this.logger.exit("getServletPath");
           return result;
       }
   
       public String getRequestedSessionId()
       {
  -        return m_Request.getRequestedSessionId();
  +        return this.request.getRequestedSessionId();
       }
   
       public StringBuffer getRequestURL()
       {
  -        return m_Request.getRequestURL();
  +        return this.request.getRequestURL();
       }
   
       /**
  @@ -188,26 +193,26 @@
        */
       public String getRequestURI()
       {
  -        m_Logger.entry("getRequestURI()");
  +        this.logger.entry("getRequestURI()");
   
  -        String result = m_Request.getRequestURI();
  +        String result = this.request.getRequestURI();
   
  -        if (m_URL != null) {
  +        if (this.url != null) {
   
               result = getContextPath() + 
                   ((getServletPath() == null) ? "" : getServletPath()) + 
                   ((getPathInfo() == null) ? "" : getPathInfo());
   
  -            m_Logger.debug("Using simulated request URI : [" + result + "]");
  +            this.logger.debug("Using simulated request URI : [" + result + "]");
           }
   
  -        m_Logger.exit("getRequestURI");
  +        this.logger.exit("getRequestURI");
           return result;
       }
   
       public String getRemoteUser()
       {
  -        return m_Request.getRemoteUser();
  +        return this.request.getRemoteUser();
       }
   
       /**
  @@ -216,22 +221,23 @@
        */
       public String getQueryString()
       {
  -        m_Logger.entry("getQueryString()");
  +        this.logger.entry("getQueryString()");
   
  -        String result = m_Request.getQueryString();
  +        String result = this.request.getQueryString();
   
  -        if (m_URL != null) {
  -            result = m_URL.getQueryString();
  -            m_Logger.debug("Using simulated query string : [" + result + "]");
  +        if (this.url != null) {
  +            result = this.url.getQueryString();
  +            this.logger.debug("Using simulated query string : [" + result +
  +                "]");
           }
   
  -        m_Logger.exit("getQueryString");
  +        this.logger.exit("getQueryString");
           return result;
       }
   
       public String getPathTranslated()
       {
  -        return m_Request.getPathTranslated();
  +        return this.request.getPathTranslated();
       }
   
       /**
  @@ -240,52 +246,52 @@
        */
       public String getPathInfo()
       {
  -        m_Logger.entry("getPathInfo()");
  +        this.logger.entry("getPathInfo()");
   
  -        String result = m_Request.getPathInfo();
  +        String result = this.request.getPathInfo();
   
  -        if (m_URL != null) {
  -            result = m_URL.getPathInfo();
  -            m_Logger.debug("Using simulated PathInfo : [" + result + "]");
  +        if (this.url != null) {
  +            result = this.url.getPathInfo();
  +            this.logger.debug("Using simulated PathInfo : [" + result + "]");
           }
   
  -        m_Logger.exit("getPathInfo");
  +        this.logger.exit("getPathInfo");
           return result;
       }
   
       public String getMethod()
       {
  -        return m_Request.getMethod();
  +        return this.request.getMethod();
       }
   
       public int getIntHeader(String theName)
       {
  -        return m_Request.getIntHeader(theName);
  +        return this.request.getIntHeader(theName);
       }
   
       public Enumeration getHeaders(String theName)
       {
  -        return m_Request.getHeaders(theName);
  +        return this.request.getHeaders(theName);
       }
   
       public Enumeration getHeaderNames()
       {
  -        return m_Request.getHeaderNames();
  +        return this.request.getHeaderNames();
       }
   
       public String getHeader(String theName)
       {
  -        return m_Request.getHeader(theName);
  +        return this.request.getHeader(theName);
       }
   
       public long getDateHeader(String theName)
       {
  -        return m_Request.getDateHeader(theName);
  +        return this.request.getDateHeader(theName);
       }
   
       public Cookie[] getCookies()
       {
  -        return m_Request.getCookies();
  +        return this.request.getCookies();
       }
   
       /**
  @@ -294,44 +300,45 @@
        */
       public String getContextPath()
       {
  -        m_Logger.entry("getContextPath()");
  +        this.logger.entry("getContextPath()");
   
  -        String result = m_Request.getContextPath();
  +        String result = this.request.getContextPath();
   
  -        if (m_URL != null) {
  -            if (m_URL.getContextPath() != null) {
  -                result = m_URL.getContextPath();
  -                m_Logger.debug("Using simulated context : [" + result + "]");
  +        if (this.url != null) {
  +            if (this.url.getContextPath() != null) {
  +                result = this.url.getContextPath();
  +                this.logger.debug("Using simulated context : [" + result + "]");
               }
           }
   
  -        m_Logger.exit("getContextPath");
  +        this.logger.exit("getContextPath");
           return result;
       }
   
       public String getAuthType()
       {
  -        return m_Request.getAuthType();
  +        return this.request.getAuthType();
       }
   
  -    public void setCharacterEncoding(String env) throws UnsupportedEncodingException
  +    public void setCharacterEncoding(String env)
  +        throws UnsupportedEncodingException
       {
  -        m_Request.setCharacterEncoding(env);
  +        this.request.setCharacterEncoding(env);
       }
   
       public void setAttribute(String theName, Object theAttribute)
       {
  -        m_Request.setAttribute(theName, theAttribute);
  +        this.request.setAttribute(theName, theAttribute);
       }
   
       public void removeAttribute(String theName)
       {
  -        m_Request.removeAttribute(theName);
  +        this.request.removeAttribute(theName);
       }
   
       public boolean isSecure()
       {
  -        return m_Request.isSecure();
  +        return this.request.isSecure();
       }
   
       /**
  @@ -341,16 +348,16 @@
        */
       public int getServerPort()
       {
  -        m_Logger.entry("getServerPort()");
  +        this.logger.entry("getServerPort()");
   
  -        int result = m_Request.getServerPort();
  +        int result = this.request.getServerPort();
   
  -        if (m_URL != null) {
  -            result = (m_URL.getPort() == -1) ? 80 : m_URL.getPort();
  -            m_Logger.debug("Using simulated server port : [" + result + "]");
  +        if (this.url != null) {
  +            result = (this.url.getPort() == -1) ? 80 : this.url.getPort();
  +            this.logger.debug("Using simulated server port : [" + result + "]");
           }
   
  -        m_Logger.exit("getServerPort");
  +        this.logger.exit("getServerPort");
           return result;
       }
   
  @@ -360,24 +367,25 @@
        */
       public String getServerName()
       {
  -        m_Logger.entry("getServerName()");
  +        this.logger.entry("getServerName()");
   
  -        String result = m_Request.getServerName();
  +        String result = this.request.getServerName();
   
  -        if (m_URL != null) {
  -            if (m_URL.getServerName() != null) {
  -                result = m_URL.getHost();
  -                m_Logger.debug("Using simulated server name : [" + result + "]");
  +        if (this.url != null) {
  +            if (this.url.getServerName() != null) {
  +                result = this.url.getHost();
  +                this.logger.debug("Using simulated server name : [" + result +
  +                    "]");
               }
           }
   
  -        m_Logger.exit("getServerName");
  +        this.logger.exit("getServerName");
           return result;
       }
   
       public String getScheme()
       {
  -        return m_Request.getScheme();
  +        return this.request.getScheme();
       }
   
       /**
  @@ -389,7 +397,7 @@
        */
       public RequestDispatcher getRequestDispatcher(String thePath)
       {
  -        m_Logger.entry("getRequestDispatcher([" + thePath + "])");
  +        this.logger.entry("getRequestDispatcher([" + thePath + "])");
   
           // I hate it, but we have to write some logic here ! Ideally we
           // shouldn't have to do this as it is supposed to be done by the servlet
  @@ -398,7 +406,7 @@
           // (it has to mock some parts of the servlet engine) !
   
           if (thePath == null) {
  -            m_Logger.exit("getRequestDispatcher");
  +            this.logger.exit("getRequestDispatcher");
               return null;
           }
   
  @@ -422,18 +430,18 @@
               }
   
                if (fullPath == null) {
  -                m_Logger.exit("getRequestDispatcher");
  +                this.logger.exit("getRequestDispatcher");
                   return null;
               }
   
           }
                   
  -        m_Logger.debug("Computed full path : [" + fullPath + "]");
  +        this.logger.debug("Computed full path : [" + fullPath + "]");
   
           dispatcher = new RequestDispatcherWrapper(
  -            m_Request.getRequestDispatcher(fullPath));
  +            this.request.getRequestDispatcher(fullPath));
   
  -        m_Logger.exit("getRequestDispatcher");
  +        this.logger.exit("getRequestDispatcher");
           return dispatcher;
       }
   
  @@ -469,87 +477,87 @@
   
       public String getRemoteHost()
       {
  -        return m_Request.getRemoteHost();
  +        return this.request.getRemoteHost();
       }
   
       public String getRemoteAddr()
       {
  -        return m_Request.getRemoteAddr();
  +        return this.request.getRemoteAddr();
       }
   
       public String getRealPath(String thePath)
       {
  -        return m_Request.getRealPath(thePath);
  +        return this.request.getRealPath(thePath);
       }
   
       public BufferedReader getReader() throws IOException
       {
  -        return m_Request.getReader();
  +        return this.request.getReader();
       }
   
       public String getProtocol()
       {
  -        return m_Request.getProtocol();
  +        return this.request.getProtocol();
       }
   
       public String[] getParameterValues(String theName)
       {
  -        return m_Request.getParameterValues(theName);
  +        return this.request.getParameterValues(theName);
       }
   
       public Enumeration getParameterNames()
       {
  -        return m_Request.getParameterNames();
  +        return this.request.getParameterNames();
       }
   
       public Map getParameterMap()
       {
  -        return m_Request.getParameterMap();
  +        return this.request.getParameterMap();
       }
   
       public String getParameter(String theName)
       {
  -        return m_Request.getParameter(theName);
  +        return this.request.getParameter(theName);
       }
   
       public Enumeration getLocales()
       {
  -        return m_Request.getLocales();
  +        return this.request.getLocales();
       }
   
       public Locale getLocale()
       {
  -        return m_Request.getLocale();
  +        return this.request.getLocale();
       }
   
       public ServletInputStream getInputStream() throws IOException
       {
  -        return m_Request.getInputStream();
  +        return this.request.getInputStream();
       }
   
       public String getContentType()
       {
  -        return m_Request.getContentType();
  +        return this.request.getContentType();
       }
   
       public int getContentLength()
       {
  -        return m_Request.getContentLength();
  +        return this.request.getContentLength();
       }
   
       public String getCharacterEncoding()
       {
  -        return m_Request.getCharacterEncoding();
  +        return this.request.getCharacterEncoding();
       }
   
       public Enumeration getAttributeNames()
       {
  -        return m_Request.getAttributeNames();
  +        return this.request.getAttributeNames();
       }
   
       public Object getAttribute(String theName)
       {
  -        return m_Request.getAttribute(theName);
  +        return this.request.getAttribute(theName);
       }
   
   }
  
  
  
  1.2       +7 -5      
jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/RequestDispatcherWrapper.java
  
  Index: RequestDispatcherWrapper.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/RequestDispatcherWrapper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- RequestDispatcherWrapper.java     2001/04/09 11:52:35     1.1
  +++ RequestDispatcherWrapper.java     2001/08/19 15:27:49     1.2
  @@ -63,21 +63,23 @@
    * <code>forward()</code> and <code>include</code> methods to use the original
    * HTTP request object instead of the simulated one used by Cactus.
    *
  - * @version @version@
  + * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
  + *
  + * @version $Id: RequestDispatcherWrapper.java,v 1.2 2001/08/19 15:27:49 vmassol 
Exp $
    */
   public class RequestDispatcherWrapper implements RequestDispatcher
   {
       /**
        * The original request dispatcher object
        */
  -     private RequestDispatcher m_OriginalDispatcher;
  +     private RequestDispatcher originalDispatcher;
   
       /**
        * @param theOriginalDispatcher the original request dispatcher object
        */
       public RequestDispatcherWrapper(RequestDispatcher theOriginalDispatcher)
       {
  -        m_OriginalDispatcher = theOriginalDispatcher;
  +        this.originalDispatcher = theOriginalDispatcher;
       }
   
       /**
  @@ -91,7 +93,7 @@
       public void forward(ServletRequest theRequest, ServletResponse theResponse) 
throws IOException, ServletException
       {
           HttpServletRequestWrapper request = (HttpServletRequestWrapper)theRequest;
  -        m_OriginalDispatcher.forward(request.getOriginalRequest(), theResponse);
  +        this.originalDispatcher.forward(request.getOriginalRequest(), theResponse);
       }
   
       /**
  @@ -105,7 +107,7 @@
       public void include(ServletRequest theRequest, ServletResponse theResponse) 
throws IOException, ServletException
       {
           HttpServletRequestWrapper request = (HttpServletRequestWrapper)theRequest;
  -        m_OriginalDispatcher.include(request.getOriginalRequest(), theResponse);
  +        this.originalDispatcher.include(request.getOriginalRequest(), theResponse);
       }
   
   }
  
  
  
  1.2       +20 -17    
jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/ServletConfigWrapper.java
  
  Index: ServletConfigWrapper.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/ServletConfigWrapper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ServletConfigWrapper.java 2001/04/09 11:52:35     1.1
  +++ ServletConfigWrapper.java 2001/08/19 15:27:49     1.2
  @@ -66,7 +66,9 @@
    * <code>getServletContext()</code> method to return our own wrapper around
    * <code>ServletContext</code>.
    *
  - * @version @version@
  + * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
  + *
  + * @version $Id: ServletConfigWrapper.java,v 1.2 2001/08/19 15:27:49 vmassol Exp $
    * @see ServletContext
    */
   public class ServletConfigWrapper implements ServletConfig
  @@ -74,25 +76,25 @@
       /**
        * The original servlet config object
        */
  -    private ServletConfig m_OriginalConfig;
  +    private ServletConfig originalConfig;
   
       /**
        * List of parameters set using the <code>setInitParameter()</code> method.
        */
  -    private Hashtable m_InitParameters;
  +    private Hashtable initParameters;
   
       /**
        * Simulated name of the servlet
        */
  -    private String m_ServletName;
  +    private String servletName;
   
       /**
        * @param theOriginalConfig the original servlet config object
        */
       public ServletConfigWrapper(ServletConfig theOriginalConfig)
       {
  -        m_OriginalConfig = theOriginalConfig;
  -        m_InitParameters = new Hashtable();
  +        this.originalConfig = theOriginalConfig;
  +        this.initParameters = new Hashtable();
       }
   
       /**
  @@ -103,7 +105,7 @@
        */
       public void setInitParameter(String theName, String theValue)
       {
  -        m_InitParameters.put(theName, theValue);
  +        this.initParameters.put(theName, theValue);
       }
   
       /**
  @@ -114,10 +116,10 @@
        */
       public void setServletName(String theServletName)
       {
  -        m_ServletName = theServletName;
  +        this.servletName = theServletName;
       }
   
  -    //--Overridden methods -----------------------------------------------------
  +    //--Overridden methods ----------------------------------------------------
   
       /**
        * @return the simulated servlet's name if defined or the redirector
  @@ -125,11 +127,11 @@
        */
       public String getServletName()
       {
  -        if (m_ServletName != null) {
  -            return m_ServletName;
  +        if (this.servletName != null) {
  +            return this.servletName;
           }
   
  -        return m_OriginalConfig.getServletName();
  +        return this.originalConfig.getServletName();
       }
   
       /**
  @@ -137,7 +139,8 @@
        */
       public ServletContext getServletContext()
       {
  -        return new ServletContextWrapper(m_OriginalConfig.getServletContext());
  +        return new ServletContextWrapper(
  +            this.originalConfig.getServletContext());
       }
   
       /**
  @@ -149,13 +152,13 @@
       {
           Vector names = new Vector();
   
  -        Enumeration enum = m_InitParameters.keys();
  +        Enumeration enum = this.initParameters.keys();
           while (enum.hasMoreElements()) {
               String value = (String)enum.nextElement();
               names.add(value);
           }
   
  -        enum = m_OriginalConfig.getInitParameterNames();
  +        enum = this.originalConfig.getInitParameterNames();
           while (enum.hasMoreElements()) {
               String value = (String)enum.nextElement();
               names.add(value);
  @@ -174,9 +177,9 @@
       {
           // Look first in the list of parameters set using the
           // setInitParameter() method.
  -        String value = (String)m_InitParameters.get(theName);
  +        String value = (String)this.initParameters.get(theName);
           if (value == null) {
  -            value = m_OriginalConfig.getInitParameter(theName);
  +            value = this.originalConfig.getInitParameter(theName);
           }
   
           return value;
  
  
  
  1.2       +47 -34    
jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/ServletContextWrapper.java
  
  Index: ServletContextWrapper.java
  ===================================================================
  RCS file: 
/home/cvs/jakarta-commons/cactus/src/framework/servlet23/org/apache/commons/cactus/server/ServletContextWrapper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ServletContextWrapper.java        2001/04/09 11:52:35     1.1
  +++ ServletContextWrapper.java        2001/08/19 15:27:49     1.2
  @@ -67,7 +67,9 @@
    * <code>getRequestDispatcher()</code> method to return our own wrapper around
    * <code>RequestDispatcher</code>.
    *
  - * @version @version@
  + * @author <a href="mailto:[EMAIL PROTECTED]";>Vincent Massol</a>
  + *
  + * @version $Id: ServletContextWrapper.java,v 1.2 2001/08/19 15:27:49 vmassol Exp $
    * @see RequestDispatcherWrapper
    */
   public class ServletContextWrapper implements ServletContext
  @@ -75,64 +77,64 @@
       /**
        * The original servlet context object
        */
  -    private ServletContext m_OriginalContext;
  +    private ServletContext originalContext;
   
       /**
        * @param theOriginalContext the original servlet context object
        */
       public ServletContextWrapper(ServletContext theOriginalContext)
       {
  -        m_OriginalContext = theOriginalContext;
  +        this.originalContext = theOriginalContext;
       }
   
       public void setAttribute(String theName, Object theAttribute)
       {
  -        m_OriginalContext.setAttribute(theName, theAttribute);
  +        this.originalContext.setAttribute(theName, theAttribute);
       }
   
       public void removeAttribute(String theName)
       {
  -        m_OriginalContext.removeAttribute(theName);
  +        this.originalContext.removeAttribute(theName);
       }
   
       public void log(String theMessage, Throwable theCause)
       {
  -        m_OriginalContext.log(theMessage, theCause);
  +        this.originalContext.log(theMessage, theCause);
       }
   
       public void log(String theMessage)
       {
  -        m_OriginalContext.log(theMessage);
  +        this.originalContext.log(theMessage);
       }
   
       public void log(Exception theException, String theMessage)
       {
  -        m_OriginalContext.log(theException, theMessage);
  +        this.originalContext.log(theException, theMessage);
       }
   
       public Enumeration getServlets()
       {
  -        return m_OriginalContext.getServlets();
  +        return this.originalContext.getServlets();
       }
   
       public Enumeration getServletNames()
       {
  -        return m_OriginalContext.getServletNames();
  +        return this.originalContext.getServletNames();
       }
   
       public String getServletContextName()
       {
  -        return m_OriginalContext.getServletContextName();
  +        return this.originalContext.getServletContextName();
       }
   
       public Servlet getServlet(String theName) throws ServletException
       {
  -        return m_OriginalContext.getServlet(theName);
  +        return this.originalContext.getServlet(theName);
       }
   
       public String getServerInfo()
       {
  -        return m_OriginalContext.getServerInfo();
  +        return this.originalContext.getServerInfo();
       }
   
       public Set getResourcePaths()
  @@ -142,15 +144,20 @@
           // Use reflection because newest Servlet API 2.3 changes removed this
           // method
           try {
  -            Method method = 
m_OriginalContext.getClass().getMethod("getResourcePaths", null);
  +            Method method = this.originalContext.getClass().
  +                getMethod("getResourcePaths", null);
  +
               if (method != null) {
  -                returnSet = (Set)method.invoke(m_OriginalContext, null);
  +                returnSet = (Set)method.invoke(this.originalContext, null);
               } else {
  -                throw new RuntimeException("Method 
ServletContext.getResourcePaths() no longer supported by your servlet engine !");
  +                throw new RuntimeException("Method ServletContext." +
  +                    "getResourcePaths() no longer supported by your servlet " +
  +                    "engine !");
               }
           } catch (Exception e) {
               e.printStackTrace();
  -            throw new RuntimeException("Error getting/calling method 
getResourcePaths()");
  +            throw new RuntimeException("Error getting/calling method " +
  +                "getResourcePaths()");
           }
   
           return returnSet;
  @@ -169,15 +176,21 @@
           // Check if the method exist (for servlet engines that do not have
           // upgraded yet)
           try {
  -            Method method = 
m_OriginalContext.getClass().getMethod("getResourcePaths", new Class[] { String.class 
});
  +            Method method = this.originalContext.getClass().
  +                getMethod("getResourcePaths", new Class[] { String.class });
  +
               if (method != null) {
  -                returnSet = (Set)method.invoke(m_OriginalContext, new Object[] { 
thePath });
  +                returnSet = (Set)method.invoke(this.originalContext,
  +                    new Object[] { thePath });
               } else {
  -                throw new RuntimeException("Method 
ServletContext.getResourcePaths(String path) not supported yet by your servlet engine 
!");
  +                throw new RuntimeException("Method ServletContext." +
  +                    "getResourcePaths(String path) not supported yet by your " +
  +                    "servlet engine !");
               }
           } catch (Exception e) {
               e.printStackTrace();
  -            throw new RuntimeException("Error getting/calling method 
getResourcePaths(String path)");
  +            throw new RuntimeException("Error getting/calling method " +
  +                "getResourcePaths(String path)");
           }
   
           return returnSet;
  @@ -185,12 +198,12 @@
   
       public InputStream getResourceAsStream(String thePath)
       {
  -        return m_OriginalContext.getResourceAsStream(thePath);
  +        return this.originalContext.getResourceAsStream(thePath);
       }
   
       public URL getResource(String thePath) throws MalformedURLException
       {
  -        return m_OriginalContext.getResource(thePath);
  +        return this.originalContext.getResource(thePath);
       }
   
       /**
  @@ -199,13 +212,13 @@
       public RequestDispatcher getRequestDispatcher(String thePath)
       {
           RequestDispatcher dispatcher = new RequestDispatcherWrapper(
  -            m_OriginalContext.getRequestDispatcher(thePath));
  +            this.originalContext.getRequestDispatcher(thePath));
           return dispatcher;
       }
   
       public String getRealPath(String thePath)
       {
  -        return m_OriginalContext.getRealPath(thePath);
  +        return this.originalContext.getRealPath(thePath);
       }
   
       /**
  @@ -214,33 +227,33 @@
       public RequestDispatcher getNamedDispatcher(String theName)
       {
           RequestDispatcher dispatcher = new RequestDispatcherWrapper(
  -            m_OriginalContext.getNamedDispatcher(theName));
  +            this.originalContext.getNamedDispatcher(theName));
           return dispatcher;
       }
   
       public int getMinorVersion()
       {
  -        return m_OriginalContext.getMinorVersion();
  +        return this.originalContext.getMinorVersion();
       }
   
       public String getMimeType(String theFilename)
       {
  -        return m_OriginalContext.getMimeType(theFilename);
  +        return this.originalContext.getMimeType(theFilename);
       }
   
       public int getMajorVersion()
       {
  -        return m_OriginalContext.getMajorVersion();
  +        return this.originalContext.getMajorVersion();
       }
   
       public Enumeration getInitParameterNames()
       {
  -        return m_OriginalContext.getInitParameterNames();
  +        return this.originalContext.getInitParameterNames();
       }
   
       public String getInitParameter(String theName)
       {
  -        return m_OriginalContext.getInitParameter(theName);
  +        return this.originalContext.getInitParameter(theName);
       }
   
       /**
  @@ -249,18 +262,18 @@
       public ServletContext getContext(String theUripath)
       {
           ServletContext context = new ServletContextWrapper(
  -            m_OriginalContext.getContext(theUripath));
  +            this.originalContext.getContext(theUripath));
           return context;
       }
   
       public Enumeration getAttributeNames()
       {
  -        return m_OriginalContext.getAttributeNames();
  +        return this.originalContext.getAttributeNames();
       }
   
       public Object getAttribute(String theName)
       {
  -        return m_OriginalContext.getAttribute(theName);
  +        return this.originalContext.getAttribute(theName);
       }
   
   }
  
  
  

Reply via email to