You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by Joseph Kesselman <ke...@us.ibm.com> on 2002/06/25 15:14:37 UTC

Re: Xalan C++ document() tech question

                                                                                                               
                                                                                                               
                                                                                                               


>Could someone tell me how/when/where the "document()" XSLT function
>actually happens...

The FuncDocument class currently implements this. Note that it's basically
a call to DTMManager's getDTM operation.

The current implementation of DTMManager does perform some caching, so if
you're repeatedly accessing the same document within a single
transformation, I _think_ we will simply re-access the same DTM.

If you want to do some explicit caching, the easiest approach would be to
assign the retrieved document to an XSLT variable and then use the
variable, possibly via our provided nodeset() extension function.

(It's worth noting that the current working draft for XSLT2 removes the
need for that extension; the current plan is that it will allow you to
directly search variables containing "temporary trees".)

______________________________________
Joe Kesselman  / IBM Research