Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: Question about union operator (|)

From: David Carlisle <david-news@---------.-----.--.-->
To: NULL
Date: 9/1/2007 12:21:00 AM

Richard Tobin wrote:
> In article <fba0kl$fdl$1$8300dec7@n...>,
> David Carlisle  <david-news@d...> wrote:
> 
>>> As I undertood:
>>> XPath evaluates expressions to unordered node-sets.
>>> The direction of axis in XPath is significant only when location step
>>> contains predicates.
>>> In other cases the order of nodes in a node-set defines by external to
>>> XPath application (for example XSLT).
> 
>> Not really, the ordering is intrinsic to the Xpath 1 data model, not 
>> something added by XSLT.
> 
> I think you're mistaken here.  In XPath 1 itself, the only place that
> the ordering is an issue is when a predicate is used,

ah but I didn't say it makes a difference, only that it (document order) 
is intrinsic to the xpath data model. It's not added by xslt. I was 
wrong to say xpath uses the term current node list though, that 
terminology isn't used in xpath as you say. (it could have been but the 
effect of position() is described directly without giving a name to the 
"node set in document or reverse document order"

> and XPath
> expresses that by saying that predicates filter a node set with
> respect to an axis.

yes thanks for the correction.
> 
>> XPath/XSLt1 is always careful to distinguish a "node set" fom the 
>> "current node list" the current node list is an ordered list and is what 
>> is used to evaluate position() etc. In XPath1 though, the current node 
>> list is a transient object that can not be returned as a result of an 
>> expression.
> 
> XPath 1 doesn't mention current node lists.  They are introduced in
> XSLT 1.  XPath 1 has only unordered node sets and filtering with
> respect to an axis.

True, but the point I was trying to make (not that well:-) was that 
these are sets over an ordered domain.
> 
> Of course this is just a matter of exposition: the same XPath 1
> language could be defined in terms of node lists rather than sets; the
> lists generated by a reverse axis could be in reverse document order;
> and filter expressions would have to be defined to put their left
> operand into document order.
> 
> -- Richard

which is closer to the xpath2 way. Not just filter expressions, but also 
/ for example need to invoke re-ordering (or removal of duplicates) as 
would |.

David
-- 
http://dpcarlisle.blogspot.com


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent