garyp 00/10/13 17:33:24
Modified: java/src/org/apache/xalan/transformer TransformerImpl.java
Log:
Initialize extension declarations in included stylesheets.
Revision Changes Path
1.33 +23 -6
xml-xalan/java/src/org/apache/xalan/transformer/TransformerImpl.java
Index: TransformerImpl.java
===================================================================
RCS file:
/home/cvs/xml-xalan/java/src/org/apache/xalan/transformer/TransformerImpl.java,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -r1.32 -r1.33
--- TransformerImpl.java 2000/10/13 02:33:13 1.32
+++ TransformerImpl.java 2000/10/14 00:33:22 1.33
@@ -653,13 +653,24 @@
int n = stylesheet.getGlobalImportCount();
for(int i = 0; i < n; i++)
{
- Stylesheet imported = stylesheet.getGlobalImport(i);
+ StylesheetComposed imported = stylesheet.getGlobalImport(i);
imported.runtimeInit(this);
for(ElemTemplateElement child = imported.getFirstChildElem();
child != null; child = child.getNextSiblingElem())
{
child.runtimeInit(this);
}
+ int includedCount = imported.getIncludeCountComposed();
+ for (int j = 0; j < includedCount; j++)
+ {
+ Stylesheet included = imported.getIncludeComposed(i);
+ included.runtimeInit(this);
+ for(ElemTemplateElement child = included.getFirstChildElem();
+ child != null; child = child.getNextSiblingElem())
+ {
+ child.runtimeInit(this);
+ }
+ }
}
// ===========
@@ -1946,14 +1957,18 @@
* to be unable to return its value; this is especially true
* in the case of an adapter for a SAX1 Parser, which has
* no way of knowing whether the underlying parser is
- * validating, for example.</p>
*
* <h3>Open issues:</h3>
- * <dl>
* <dt><h4>Should getFeature be changed to hasFeature?</h4></dt>
+ * validating, for example.</p>
+ *
+ * <h3>Open issues:</h3>
+ * <dl>
+ * <dt><h4>Should getFeature be changed to hasFeature?</h4></dt>
* <dd>Keith Visco writes: Should getFeature be changed to hasFeature?
* It returns a boolean which indicated whether the "state"
* of feature is "true or false". I assume this means whether
* or not a feature is supported? I know SAX is using "getFeature",
* but to me "hasFeature" is cleaner.</dd>
- * </dl>
*
+ * </dl>
+ *
* @param name The feature name, which is a fully-qualified
* URI.
* @return The current state of the feature (true or false).
@@ -1964,11 +1979,13 @@
* cannot determine its value at this time.
*/
public boolean getFeature (String name)
- throws SAXNotRecognizedException, SAXNotSupportedException
{
+ throws SAXNotRecognizedException, SAXNotSupportedException
+ {
if("http://xml.org/trax/features/sax/input".equals(name))
return true;
else if("http://xml.org/trax/features/dom/input".equals(name))
- return true;
throw new SAXNotRecognizedException(name);
+ return true;
+ throw new SAXNotRecognizedException(name);
}
////////////////////////