This JAXP API is flawed by design, since XSL is defined by specification to operate on XML infosets (in-memory trees), *not* event streams or partial documents. Therefore until now the GNU TransformerFactory implementation has not implemented this interface nor advertised such conformance.
However, there is existing code out there that casts the TransformerFactory blindly to a SAXTransformerFactory without checking whether it advertises conformance (getFeature (SAXTransformerFactory.FEATURE)). While such code is not guaranteed to work on a conformant Java implementation it does work on Sun's and until now would fail on Classpath.
This patch implements SAXTransformerFactory by providing an implementation that will buffer all SAX events into an in-memory tree and then use this tree as the basis of existing transformer operations, and will make such aforementioned code work on Classpath providing that they do not attempt transformer operations during the actual parsing.
2006-09-17 Chris Burdess <[EMAIL PROTECTED]>
Fixes PR 27610 27687.
* gnu/xml/dom/ls/SAXEventSink.java: Permit limited subclassing.
* gnu/xml/transform/SAXTemplatesHandler.java,
* gnu/xml/transform/SAXTransformerHandler.java: New files.
* gnu/xml/transform/TransformerFactoryImpl.java: Implement
SAXTransformerFactory.
--
犬 Chris Burdess
"They that can give up essential liberty to obtain a little safety
deserve neither liberty nor safety." - Benjamin Franklin
patch
Description: Binary data
PGP.sig
Description: This is a digitally signed message part
