This is a question regarding the Apache Xalan XSLT 3 development branch that has support for xsl:result-document to have a single XSLT transformation create more than one result document, i.e. to use xsl:result-document to create secondary result documents.

With Saxon, in Java code (though using Saxon's s9api, not JAXP), it is possible to handle those result documents in your code with https://www.saxonica.com/html/documentation12/javadoc/net/sf/saxon/s9api/AbstractXsltTransformer.html#setResultDocumentHandler(java.util.function.Function).

Is there any way to do this in Xalan or is any API planned?

The reason why I ask: in my XSLT fiddles for Saxon I tend to capture the result documents and that way ensure they are selectable and viewable for the fiddle user; I would like to do the same for my fiddle using the Xalan XSLT 3.0 development branch.

As you have fn:transform support, I think, where you have to return all results as an XDM map, perhaps it is easy to turn that into an API; or I should explore doing XPath 3.1 and fn:transform in my fiddle instead of using Transformer to run XSLT 3.0 code.

Reply via email to