W3C home > Mailing lists > Public > www-xpath-comments@w3.org > July to September 1999

Re: Context of an XPath expression

From: James Clark <jjc@jclark.com>
Date: Mon, 13 Sep 1999 19:42:24 +0700
Message-ID: <37DCF12F.8ED593F5@jclark.com>
To: Kay Michael <Michael.Kay@icl.com>
CC: "'www-xpath-comments@w3.org'" <www-xpath-comments@w3.org>
Kay Michael wrote:
> The components of the context described in the XPath specification (section
> 1) are not sufficient to evaluate all XSLT expressions.

There's nothing that says that the XSLT processor has to pass the same
function library to every expression.  Although you can think of the
things you mention as additional items of context, I prefer to think of
the XSLT processor as passing a context-specific function. For example,
if the current node is X, then the XSLT processor will pass a function
library that binds "current" to a function that returns node X.  I think
this gives a cleaner interface between XPath and XSLT.

> 1: the XSLT document() function uses another piece of context (the base URL
> of the stylesheet node containing the expression)
> 2: the XSLT current() function uses another piece of context (the current
> node in the source document).
> 3: the XSLT system-property() function depends on a rather nebulous context
> called the "operating system".
> It would be useful to at least acknowledge that functions outside the core
> library may depend on other contextual information.
> Also, there is still nothing said about whether non-core functions can have
> side effects.
> Mike Kay
Received on Monday, 13 September 1999 08:52:58 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:02:13 UTC