tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From craig...@locus.apache.org
Subject cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core ApplicationDispatcher.java
Date Sat, 28 Oct 2000 18:56:04 GMT
craigmcc    00/10/28 11:56:04

  Modified:    catalina/src/share/org/apache/catalina Globals.java
               catalina/src/share/org/apache/catalina/core
                        ApplicationDispatcher.java
  Log:
  Migrate the manifest constants for request attributes created in the
  RequestDispatcher implementation into the global constants file.
  
  Correct the punctuation of the request attributes for cipher suite and key
  size, per Section 4.7 of Servlet 2.3 PFD.
  
  Revision  Changes    Path
  1.12      +54 -6     jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/Globals.java
  
  Index: Globals.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/Globals.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- Globals.java	2000/10/13 19:27:33	1.11
  +++ Globals.java	2000/10/28 18:56:03	1.12
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/Globals.java,v
1.11 2000/10/13 19:27:33 craigmcc Exp $
  - * $Revision: 1.11 $
  - * $Date: 2000/10/13 19:27:33 $
  + * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/Globals.java,v
1.12 2000/10/28 18:56:03 craigmcc Exp $
  + * $Revision: 1.12 $
  + * $Date: 2000/10/28 18:56:03 $
    *
    * ====================================================================
    *
  @@ -69,7 +69,7 @@
    * Global constants that are applicable to multiple packages within Catalina.
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.11 $ $Date: 2000/10/13 19:27:33 $
  + * @version $Revision: 1.12 $ $Date: 2000/10/28 18:56:03 $
    */
   
   public final class Globals {
  @@ -90,7 +90,7 @@
        * java.lang.String).
        */
       public static final String CIPHER_SUITE_ATTR =
  -        "javax.servlet.request.cipher_suite";
  +        "javax.servlet.request.cipher-suite";
   
   
       /**
  @@ -111,6 +111,14 @@
   
   
       /**
  +     * The request attribute under which the original context path is stored
  +     * on an included dispatcher request.
  +     */
  +    public static final String CONTEXT_PATH_ATTR =
  +        "javax.servlet.include.context_path";
  +
  +
  +    /**
        * The request attribute under which we forward a Java exception
        * (as an object of type Throwable) to an error page.
        */
  @@ -147,14 +155,54 @@
        * this SSL connection (as an object of type java.lang.Integer).
        */
       public static final String KEY_SIZE_ATTR =
  -        "javax.servlet.request.key_size";
  +        "javax.servlet.request.key-size";
  +
  +
  +    /**
  +     * The request attribute under which we store the servlet name on a
  +     * named dispatcher request.
  +     */
  +    public static final String NAMED_DISPATCHER_ATTR =
  +        "org.apache.catalina.NAMED";
  +
  +
  +    /**
  +     * The request attribute under which the original path info is stored
  +     * on an included dispatcher request.
  +     */
  +    public static final String PATH_INFO_ATTR =
  +        "javax.servlet.include.path_info";
   
   
       /**
  +     * The request attribute under which the original query string is stored
  +     * on an included dispatcher request.
  +     */
  +    public static final String QUERY_STRING_ATTR =
  +        "javax.servlet.include.query_string";
  +
  +
  +    /**
  +     * The request attribute under which the original request URI is stored
  +     * on an included dispatcher request.
  +     */
  +    public static final String REQUEST_URI_ATTR =
  +        "javax.servlet.include.request_uri";
  +
  +
  +    /**
        * The descriptive information about this server and version.
        */
       public static final String SERVER_INFO = "Apache Tomcat/4.0-dev";
   
  +
  +
  +    /**
  +     * The request attribute under which the original servlet path is stored
  +     * on an included dispatcher request.
  +     */
  +    public static final String SERVLET_PATH_ATTR =
  +        "javax.servlet.include.servlet_path";
   
   
       /**
  
  
  
  1.8       +11 -10    jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java
  
  Index: ApplicationDispatcher.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- ApplicationDispatcher.java	2000/10/16 22:44:17	1.7
  +++ ApplicationDispatcher.java	2000/10/28 18:56:04	1.8
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java,v
1.7 2000/10/16 22:44:17 craigmcc Exp $
  - * $Revision: 1.7 $
  - * $Date: 2000/10/16 22:44:17 $
  + * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/core/ApplicationDispatcher.java,v
1.8 2000/10/28 18:56:04 craigmcc Exp $
  + * $Revision: 1.8 $
  + * $Date: 2000/10/28 18:56:04 $
    *
    * ====================================================================
    *
  @@ -78,6 +78,7 @@
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpServletResponse;
   import org.apache.catalina.Context;
  +import org.apache.catalina.Globals;
   import org.apache.catalina.Logger;
   import org.apache.catalina.Wrapper;
   import org.apache.catalina.util.StringManager;
  @@ -94,7 +95,7 @@
    * <code>javax.servlet.ServletResponseWrapper</code>.
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.7 $ $Date: 2000/10/16 22:44:17 $
  + * @version $Revision: 1.8 $ $Date: 2000/10/28 18:56:04 $
    */
   
   final class ApplicationDispatcher
  @@ -373,7 +374,7 @@
   
   	    ApplicationHttpRequest wrequest =
   		new ApplicationHttpRequest((HttpServletRequest) request);
  -            wrequest.setAttribute("org.apache.catalina.NAMED", name);
  +            wrequest.setAttribute(Globals.NAMED_DISPATCHER_ATTR, name);
   
   	    try {
   		invoke(wrequest, wresponse);
  @@ -405,19 +406,19 @@
   	    if (pathInfo != null)
   		sb.append(pathInfo);
   	    if (sb.length() > 0)
  -		wrequest.setAttribute("javax.servlet.include.request_uri",
  +		wrequest.setAttribute(Globals.REQUEST_URI_ATTR,
   				      sb.toString());
   	    if (contextPath != null)
  -		wrequest.setAttribute("javax.servlet.include.context_path",
  +		wrequest.setAttribute(Globals.CONTEXT_PATH_ATTR,
   				      contextPath);
   	    if (servletPath != null)
  -		wrequest.setAttribute("javax.servlet.include.servlet_path",
  +		wrequest.setAttribute(Globals.SERVLET_PATH_ATTR,
   				      servletPath);
   	    if (pathInfo != null)
  -		wrequest.setAttribute("javax.servlet.include.path_info",
  +		wrequest.setAttribute(Globals.PATH_INFO_ATTR,
   				      pathInfo);
   	    if (queryString != null) {
  -		wrequest.setAttribute("javax.servlet.include.query_string",
  +		wrequest.setAttribute(Globals.QUERY_STRING_ATTR,
   				      queryString);
   		wrequest.mergeParameters(queryString);
   	    }
  
  
  

Mime
View raw message