Hello,

Inside my apple (Cocoon block) I've got a org.w3c.dom.Document (coming
from a org.apache.excalibur.source.Source-object) which I'd like to
transform into another org.w3c.dom.Document using an XSL transformation
(stylesheet is available thru a Source-object); how can I do this with
the Cocoon classes?

So something like:
private Document doTheTransformation(Source xmlsrc, Source
stylesheetsrc) {
        Document outputdoc;
        
        //get the document from the source-obj            
        InputSource inputsource = new
InputSource(xmlsrc.getInputStream());
      Document inputdoc = DomHelper.parse(inputsource); 

        //do the xsl transformation using the stylesheetsrc
        Transformer transformer = .. ??
        transformer.transform(inputdoc, outputdoc);

        //return the result document
        return outputdoc;
}

Regards,
Gunter D'Hondt 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to