[jdom-interest] JDOM and XSLT

Mani Doraisamy MDoraisamy at SELECTICA.com
Wed Feb 27 11:36:42 PST 2002

thanks. the problem in applying a stylesheet to the sub tree
is that, i might not need the child elements as well. it would
be too much of overhead to loop through the content and detach
the child elements. Also it should be able to specify till what
level i need nested children for XSLT.
I am thinking of creating a dummy Element which gets the actual
node and the number of the neting i need, in the contructor and 
recursively loop till the number of nesting.
i am not sure if this would create a problem though.


-----Original Message-----
From: Laurent Bihanic [mailto:laurent.bihanic at atosorigin.com]
Sent: Wednesday, February 27, 2002 8:11 PM
To: Mani Doraisamy
Cc: jdom-interest at jdom.org
Subject: Re: [jdom-interest] JDOM and XSLT


Mani Doraisamy wrote:
> Hi all,
> What is the fastest XSLT processor available in market. I am
> using JDOM and I would like to do XSLT so that I can present
> it as HTML.

Saxon (http://saxon.sourceforge.net) can be up to 3 times faster than Xalan,

depending on your stylesheet, and is very stable.

> Another question,
> my JDOM structure is huge and the Elements in the structure
> actually gets the value from performance intensive calculations
> and database operations, by overriding getText() method. Now
> when i want to do XSLT i wouldnt want the entire tree for XSLT.
> Although i can pass the whole tree for XSLT, what is the most
> performant way of doing XSLT for the subtree?

XSLT processes an entire document. So the only way to apply a stylesheet to 
only a part of a document is to detach that part and make it a standalone 
document. You can then apply the stylesheet to this "small" document and 
attach the result back to the original document.

Hope this helps,

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://jdom.org/pipermail/jdom-interest/attachments/20020228/f39091ec/attachment.htm

More information about the jdom-interest mailing list