tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kin...@apache.org
Subject cvs commit: jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources messages.properties messages_es.properties messages_fr.properties messages_ja.properties
Date Sat, 01 Feb 2003 02:41:13 GMT
kinman      2003/01/31 18:41:13

  Modified:    jasper2/src/share/org/apache/jasper/compiler
                        JspDocumentParser.java
               jasper2/src/share/org/apache/jasper/resources
                        messages.properties messages_es.properties
                        messages_fr.properties messages_ja.properties
  Log:
  - It is now illegal to have preludes and cods assoicated with a JSP document.
  
  Revision  Changes    Path
  1.36      +14 -29    jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/JspDocumentParser.java
  
  Index: JspDocumentParser.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/compiler/JspDocumentParser.java,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -r1.35 -r1.36
  --- JspDocumentParser.java	22 Jan 2003 20:08:24 -0000	1.35
  +++ JspDocumentParser.java	1 Feb 2003 02:41:13 -0000	1.36
  @@ -150,6 +150,17 @@
   	JspDocumentParser handler = new JspDocumentParser(pc, path, inStream,
   							  isTagFile,
   							  directivesOnly);
  +	// It's an error to have a prelude or a coda associated with
  +	// a JSP document
  +	if (!handler.pageInfo.getIncludePrelude().isEmpty()) {
  +	    String file = (String) handler.pageInfo.getIncludePrelude().get(0);
  +	    handler.err.jspError("jsp.error.prelude.xml", path, file);
  +	}
  +	if (!handler.pageInfo.getIncludeCoda().isEmpty()) {
  +	    String file = (String) handler.pageInfo.getIncludeCoda().get(0);
  +	    handler.err.jspError("jsp.error.coda.xml", path, file);
  +	}
  +
   	Node.Nodes pageNodes = null;
   	Node.JspRoot jspRoot = null;
   
  @@ -160,8 +171,6 @@
   		rootAttrs.addAttribute("", "", "version", "CDATA", "2.0");
   		jspRoot = new Node.JspRoot(rootAttrs, null, null);
   		handler.current = jspRoot;
  -		handler.addInclude(jspRoot,
  -				   handler.pageInfo.getIncludePrelude());
   	    } else {
   		handler.isTop = false;
   		handler.current = parent;
  @@ -184,7 +193,6 @@
   	    saxParser.parse(handler.inputSource, handler);
   
   	    if (parent == null) {
  -		handler.addInclude(jspRoot, handler.pageInfo.getIncludeCoda());
   		// Create Node.Nodes from dummy (top-level) <jsp:root>
   		pageNodes = new Node.Nodes(jspRoot);
   	    } else {
  @@ -729,29 +737,6 @@
   		}
   	    }
   	}
  -    }
  -
  -    /*
  -     * Processes the given list of included files.
  -     *
  -     * This is used to implement the include-prelude and include-coda
  -     * subelements of the jsp-config element in web.xml
  -     */
  -    private void addInclude(Node parent, List files) throws SAXException {
  -        if (files != null) {
  -            Iterator iter = files.iterator();
  -            while (iter.hasNext()) {
  -                String file = (String) iter.next();
  -                AttributesImpl attrs = new AttributesImpl();
  -                attrs.addAttribute("", "file", "file", "CDATA", file);
  -
  -                // Create a dummy Include directive node
  -                Node includeDir = new Node.IncludeDirective(attrs, 
  -							    null, // XXX
  -							    parent);
  -                processIncludeDirective(file, includeDir);
  -            }
  -        }
       }
   
       /*
  
  
  
  1.86      +8 -6      jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages.properties
  
  Index: messages.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages.properties,v
  retrieving revision 1.85
  retrieving revision 1.86
  diff -u -r1.85 -r1.86
  --- messages.properties	28 Jan 2003 00:13:38 -0000	1.85
  +++ messages.properties	1 Feb 2003 02:41:13 -0000	1.86
  @@ -354,8 +354,10 @@
   jsp.error.tagfile.illegalPath=Illegal tag file path: {0}, must start with \"/WEB-INF/tags\"
or \"/META-INF/tags\"
   jsp.error.plugin.wrongRootElement=Name of root element in {0} different from {1}
   jsp.error.attribute.invalidPrefix=The attribute prefix {0} does not correspond to any imported
tag library
  -jsp.error.nested.jspattribute=a jsp:attribute standard action cannot be nested within another
jsp:attribute standard action
  -jsp.error.nested.jspbody=a jsp:body standard action cannot be nested within another jsp:body
or jsp:attribute standard action
  -jsp.error.variable.either.name=either name-given or name-from-attribute attribute must
be specified in a variable directive
  -jsp.error.variable.both.name=cannot specified both name-given or name-from-attribute attributes
in a variable directive
  -jsp.error.variable.alias=both or none of the name-from-attribute and alias attributes can
be specified in a variable directive.
  +jsp.error.nested.jspattribute=A jsp:attribute standard action cannot be nested within another
jsp:attribute standard action
  +jsp.error.nested.jspbody=A jsp:body standard action cannot be nested within another jsp:body
or jsp:attribute standard action
  +jsp.error.variable.either.name=Either name-given or name-from-attribute attribute must
be specified in a variable directive
  +jsp.error.variable.both.name=Cannot specified both name-given or name-from-attribute attributes
in a variable directive
  +jsp.error.variable.alias=Both or none of the name-from-attribute and alias attributes can
be specified in a variable directive
  +jsp.error.prelude.xml=The JSP document {0} has a prelude ({1}) associated with it
  +jsp.error.coda.xml=The JSP document {0} has a coda ({1}) associated with it
  
  
  
  1.32      +3 -1      jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages_es.properties
  
  Index: messages_es.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages_es.properties,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- messages_es.properties	28 Jan 2003 00:13:38 -0000	1.31
  +++ messages_es.properties	1 Feb 2003 02:41:13 -0000	1.32
  @@ -263,3 +263,5 @@
   jsp.error.variable.either.name=
   jsp.error.variable.both.name=
   jsp.error.variable.alias=
  +jsp.error.prelude.xml=
  +jsp.error.coda.xml=
  
  
  
  1.15      +3 -1      jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages_fr.properties
  
  Index: messages_fr.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages_fr.properties,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- messages_fr.properties	28 Jan 2003 00:13:38 -0000	1.14
  +++ messages_fr.properties	1 Feb 2003 02:41:13 -0000	1.15
  @@ -302,4 +302,6 @@
   jsp.error.variable.either.name=
   jsp.error.variable.both.name=
   jsp.error.variable.alias=
  +jsp.error.prelude.xml=
  +jsp.error.coda.xml=
   
  
  
  
  1.32      +3 -1      jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages_ja.properties
  
  Index: messages_ja.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/resources/messages_ja.properties,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- messages_ja.properties	28 Jan 2003 00:13:38 -0000	1.31
  +++ messages_ja.properties	1 Feb 2003 02:41:13 -0000	1.32
  @@ -294,4 +294,6 @@
   jsp.error.variable.either.name=
   jsp.error.variable.both.name=
   jsp.error.variable.alias=
  +jsp.error.prelude.xml=
  +jsp.error.coda.xml=
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message