This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

RE: catching the last node still satisfying a condition


> > Perhaps:
> >
> > foos/foo[position() < $limit][bar][last()]
> Are successive predicate legal ? And are they evaluated as
> foo[position() < $limit AND bar AND last()] or as
> (((foo[position() < $limit])[bar])last()]) ?

Of course they are legal. Each predicate is is a filter that is applied to
the node-set that remains after applying the previous filters. For filters
that don't depend on position, multiple filters are equivalent to "and", but
for positional filters, the meaning is different, because position() and
last() refer to position among the nodes that remain after previous filters.

Mike Kay


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]