xsl-list
[Top] [All Lists]

saxon:discard-document

2005-11-25 08:13:24
Here's my counter-proposal:

A User Data Element, say exslt:performance-hints:

<exslt:performance-hints>
        <only-load-once document-uri="xyz://a.b.c/a/doc" />
        <only-load-once collection-uri="xyz://a.b.c/b/collection" />
</exslt:performance-hints>

Semantics:

only-load-once gives an optimization hint to the processor that
a document will not be accessed again outside of the xslt element that
causes it to be loaded.

Since it is a performance hint, the processor is free to ignore it, if
it is doesn't believe the coder :-)
More importantly, since it's a User Data Element, the stylesheet
remains portable.

If the processor recognizes the UDE, then it proceeds as follows:

When loading such a URI, it discards the document as soon as it is
safe to do so (it only has a local scope - this may need tying down a
bit more).

If a subsequent attempt is made to load the same document, then an
non-recoverable dynamic error is raised (the user has violated the
semantics of exslt:performance-hints).
-- 
Colin Adams
Preston Lancashire

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>
  • saxon:discard-document, Colin Paul Adams <=