xalan-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mk...@apache.org
Subject cvs commit: xml-xalan/java/src/org/apache/xalan/processor ProcessorLRE.java XSLTElementDef.java XSLTSchema.java
Date Thu, 03 Oct 2002 19:13:28 GMT
mkwan       2002/10/03 12:13:28

  Modified:    java/src/org/apache/xalan/processor ProcessorLRE.java
                        XSLTElementDef.java XSLTSchema.java
  Log:
  Use one namespace for all extensions (Bugzilla 9959)
  Use the new namespace uri "http://xml.apache.org/xalan" for
  the component and script extension elements. We maintain
  backward compatibility so that using the old uri
  "http://xml.apache.org/xslt" still works.
  
  Revision  Changes    Path
  1.19      +2 -1      xml-xalan/java/src/org/apache/xalan/processor/ProcessorLRE.java
  
  Index: ProcessorLRE.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xalan/processor/ProcessorLRE.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- ProcessorLRE.java	28 Jul 2001 00:25:57 -0000	1.18
  +++ ProcessorLRE.java	3 Oct 2002 19:13:27 -0000	1.19
  @@ -249,7 +249,8 @@
             isExtension = parentElem.containsExtensionElementURI(uri);
   
             if ((false == isExtension) && (null != uri)
  -              && uri.equals(Constants.S_BUILTIN_EXTENSIONS_URL))
  +              && (uri.equals(Constants.S_BUILTIN_EXTENSIONS_URL)
  +                  || uri.equals(Constants.S_BUILTIN_OLD_EXTENSIONS_URL)))
             {
               isComponentDecl = true;
             }
  
  
  
  1.15      +4 -2      xml-xalan/java/src/org/apache/xalan/processor/XSLTElementDef.java
  
  Index: XSLTElementDef.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xalan/processor/XSLTElementDef.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- XSLTElementDef.java	30 Oct 2001 19:13:04 -0000	1.14
  +++ XSLTElementDef.java	3 Oct 2002 19:13:28 -0000	1.15
  @@ -100,7 +100,8 @@
             classObject);
       if ( (null != namespace)
       &&  (namespace.equals(Constants.S_XSLNAMESPACEURL)
  -        || namespace.equals(Constants.S_BUILTIN_EXTENSIONS_URL)) )
  +        || namespace.equals(Constants.S_BUILTIN_EXTENSIONS_URL)
  +        || namespace.equals(Constants.S_BUILTIN_OLD_EXTENSIONS_URL)))
       {
         schema.addAvailableElement(new QName(namespace, name));
         if(null != nameAlias)
  @@ -129,7 +130,8 @@
             classObject);
       if ( (null != namespace)
       &&  (namespace.equals(Constants.S_XSLNAMESPACEURL)
  -        || namespace.equals(Constants.S_BUILTIN_EXTENSIONS_URL)) )
  +        || namespace.equals(Constants.S_BUILTIN_EXTENSIONS_URL)
  +        || namespace.equals(Constants.S_BUILTIN_OLD_EXTENSIONS_URL)))
       {
         schema.addAvailableElement(new QName(namespace, name));
         if(null != nameAlias)
  
  
  
  1.31      +39 -19    xml-xalan/java/src/org/apache/xalan/processor/XSLTSchema.java
  
  Index: XSLTSchema.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xalan/processor/XSLTSchema.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -r1.30 -r1.31
  --- XSLTSchema.java	16 Sep 2002 16:29:03 -0000	1.30
  +++ XSLTSchema.java	3 Oct 2002 19:13:28 -0000	1.31
  @@ -667,6 +667,21 @@
                                     new ProcessorInclude(),
                                     null /* class object */,
                                                  20, true);
  +    
  +    XSLTAttributeDef[] scriptAttrs = new XSLTAttributeDef[]{
  +    					    new XSLTAttributeDef(null, "lang", XSLTAttributeDef.T_NMTOKEN,
  +                                                                 true, false,XSLTAttributeDef.WARNING),
  +                                            new XSLTAttributeDef(null, "src", XSLTAttributeDef.T_URL,

  +                                            			 false, false,XSLTAttributeDef.WARNING)};
  +
  +    XSLTAttributeDef[] componentAttrs = new XSLTAttributeDef[]{ 
  +                                            new XSLTAttributeDef(null, "prefix", XSLTAttributeDef.T_NMTOKEN,

  +                                            			 true, false,XSLTAttributeDef.WARNING),
  +                                            new XSLTAttributeDef(null, "elements", XSLTAttributeDef.T_STRINGLIST,

  +                                            			 false, false,XSLTAttributeDef.WARNING),
  +                                            new XSLTAttributeDef(null, "functions", XSLTAttributeDef.T_STRINGLIST,

  +                                            			 false, false,XSLTAttributeDef.WARNING)
};
  +
       XSLTElementDef[] topLevelElements = new XSLTElementDef[]
                                    {includeDef,
                                     importDef,
  @@ -810,26 +825,31 @@
                                                           Constants.S_BUILTIN_EXTENSIONS_URL,
                                                           "script",
                                                           null /*alias */,
  -                                                    new XSLTElementDef[]{ 
  +                                                    	new XSLTElementDef[]{ 
                                                           charData } /* elements */,
  -                                                        new XSLTAttributeDef[]{
  -                                                            new XSLTAttributeDef(
  -                                                                null,
  -                                                                "lang",
  -                                                                XSLTAttributeDef.T_NMTOKEN,
  -                                                                true, false,XSLTAttributeDef.WARNING),
  -                                                            new XSLTAttributeDef(
  -                                                                null, "src", XSLTAttributeDef.T_URL,
false, false,XSLTAttributeDef.WARNING) }, 
  -                                                                new ProcessorLRE(),
  -                                                                ElemExtensionScript.class
/* class object */, 20, true) },  // EMPTY
  -                                                            new XSLTAttributeDef[]{ 
  -                                                                new XSLTAttributeDef(
  -                                                                    null, "prefix", XSLTAttributeDef.T_NMTOKEN,
true, false,XSLTAttributeDef.WARNING),
  -                                                                new XSLTAttributeDef(
  -                                                                    null, "elements", XSLTAttributeDef.T_STRINGLIST,
false, false,XSLTAttributeDef.WARNING),
  -                                                                new XSLTAttributeDef(
  -                                                                    null, "functions",
XSLTAttributeDef.T_STRINGLIST, false, false,XSLTAttributeDef.WARNING) }, 
  -                                                    new ProcessorLRE(), ElemExtensionDecl.class
/* class object */),
  +                                                        scriptAttrs, 
  +                                                        new ProcessorLRE(),
  +                                                        ElemExtensionScript.class /* class
object */, 20, true) },  // EMPTY
  +                                           componentAttrs, 
  +                                           new ProcessorLRE(), ElemExtensionDecl.class
/* class object */),
  +                                  new XSLTElementDef(
  +                                           this,
  +                                           Constants.S_BUILTIN_OLD_EXTENSIONS_URL,
  +                                           "component",
  +                                           null /*alias */,
  +                                           new XSLTElementDef[]{
  +                                                    new XSLTElementDef(
  +                                                        this,
  +                                                        Constants.S_BUILTIN_OLD_EXTENSIONS_URL,
  +                                                        "script",
  +                                                        null /*alias */,
  +                                                    	new XSLTElementDef[]{ 
  +                                                        charData } /* elements */,
  +                                                        scriptAttrs, 
  +                                                        new ProcessorLRE(),
  +                                                        ElemExtensionScript.class /* class
object */, 20, true) },  // EMPTY
  +                                           componentAttrs, 
  +                                           new ProcessorLRE(), ElemExtensionDecl.class
/* class object */),
                                     exsltFunction}/* exslt */;  //end of topevelElements
       
       XSLTAttributeDef excludeResultPrefixesAttr =
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-cvs-help@xml.apache.org


Mime
View raw message