You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by bu...@apache.org on 2002/03/18 16:55:19 UTC
DO NOT REPLY [Bug 7208] New: -
XSLTC: JAXP transform fails with DOM stylesheet
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7208>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=7208
XSLTC: JAXP transform fails with DOM stylesheet
Summary: XSLTC: JAXP transform fails with DOM stylesheet
Product: XalanJ2
Version: 2.3
Platform: PC
OS/Version: Windows NT/2K
Status: NEW
Severity: Normal
Priority: Other
Component: org.apache.xalan.xsltc
AssignedTo: xalan-dev@xml.apache.org
ReportedBy: jgauthier@silverstream.com
When I perform JAXP transforms using the xsltc TransformerFactory
(i.e., "org.apache.xalan.xsltc.trax.TransformerFactoryImpl"), an exception is
thrown in the newTemplates() method if the stylesheet is provided as a DOM
document. The same code works if I use the default xalan transformer factory.
Relevant code is the following (xsldoc is a sinple stylesheet in DOM document
format).
TransformerFactory transFactory = TransformerFactory.newInstance();
DOMSource xslSource = new DOMSource(xsldoc);
Templates template = transFactory.newTemplates(xslSource);
The following exception is thrown when I execute the above code with xalan
2.3.1.
ERROR: The input document is not a stylesheet (the XSL namespace is not
declared in the root element).
javax.xml.transform.TransformerConfigurationException: Could not compile
stylesheet
at org.apache.xalan.xsltc.trax.TransformerFactoryImpl.newTemplates
(TransformerFactoryImpl.java:515)