This is pretty much a question that should be asked elsewhere as it
doesn't relate to FOP. But I think a good XSLT engine will already cache
the static portions nicely if you cache the Templates instance(s)
between XSLT calls.

instead of:
TransformerFactory factory = TransformerFactory.getInstance();
Transformer transformer = factory.newTransformer(new StreamSource(...));

you can do:
TransformerFactory factory = TransformerFactory.getInstance();

//Prepares the stylesheet. This object can be reused.
Templates stylesheet = factory.newTemplates(new StreamSource(...));

//for each XSLT run you do:
Transformer transformer = stylesheet.newTransformer();

Any luck with the advice I sent you on the value objects and SAX event
generation?

On 18.03.2003 22:24:45 Jan Zmitko wrote:
> is it possible to cache pieces of the result from the transformation. I have 
> designed my XSL Stylesheet with templates (5 templates). Two Templates 
> containes static content and these I would like cache.  My Problem ist that 
> all 
> these Stylesheets are called in one Stylesheet and this is transforming.


Jeremias Maerki


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

Reply via email to