W3C home > Mailing lists > Public > public-xml-processing-model-wg@w3.org > April 2010

RE: namespaces on p:variable?

From: <Toman_Vojtech@emc.com>
Date: Thu, 22 Apr 2010 08:11:00 -0400
Message-ID: <997C307BEB90984EBE935699389EC41C013490B8@CORPUSMX70C.corp.emc.com>
To: <public-xml-processing-model-wg@w3.org>
> I don't actually propose that we do anything about it if the answer is
> "no", but can anyone think of any case where you'd actually need
> p:namespaces on p:variable?

Hmmmmmmmmmmmmmm. One possible use case for p:namespaces in p:variable
could be to dynamically construct the namespace bindings for evaluating
the select XPath expression:

  <p:variable name="var" select="count(//foo:*)">
    <p:namespaces element="/*"/>

I think the above pipeline should work, provided the document passed to
the pipeline specifies a namespace binding for the prefix "foo" on the
document element. Implementing the same functionality without
p:namespaces would be impossible.

Received on Thursday, 22 April 2010 12:12:14 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:32:48 UTC