]
RH Bugzilla Integration commented on JBESB-3708:
------------------------------------------------
Douglas Palmer <dpalmer(a)redhat.com> changed the Status of [bug
XsltAction cannot handle org.w3c.dom.Document
---------------------------------------------
Key: JBESB-3708
URL:
https://issues.jboss.org/browse/JBESB-3708
Project: JBoss ESB
Issue Type: Bug
Components: Rosetta
Affects Versions: 4.10
Reporter: David Tucker
Assignee: Tom Cunningham
Fix For: 4.11 CP1
Currently the XsltAction can handle the following objects:
String, byte[], Reader, InputStream, File, or Source
The output from the XsltAction, when choosing DOM, is an object that implements the
interface org.w3c.dom.Document. The action can't accept the document it created to run
another transformation on it. While this scenario is remote at best, it is not unlikely
that we would want to run a transformation on a Document. I was able to create a custom
action that would allow me to put a Document into a DOMSource object. This requires extra
work anytime I want to use a Document in an XSLT and the Document interface should be an
accepted way of sending a document to be transformed. The following code was all it took
in my custom action:
DOMSource domSource = new DOMSource();
domSource.setNode(doc.getFirstChild()); //doc is an object implementing
org.w3c.dom.Document