Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - Re: Question about union operator (|) >Thread Next - Re: Question about union operator (|) Re: Question about union operator (|)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 | ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
