Skip to Content
XSLT and XPATH: A Guide to XML Transformations
book

XSLT and XPATH: A Guide to XML Transformations

by John Robert Gardner, Zarella L. Rendon
July 2001
Intermediate to advanced
592 pages
11h 16m
English
Pearson
Content preview from XSLT and XPATH: A Guide to XML Transformations

5.2. The Node-set Core Function Group

There are seven node-set functions. Each of these operates upon the current node-set at the given stage in the evaluation of the expression in which the function is called. Our <year> example is duplicated for convenience in Example 5-1.

Consider the expression count(//harvest//month). In this expression, harvest is the ancestor node from which descendant month elements are to be counted. Notice how we have used a pattern expression comprising the argument to count() function. This is because count() is a node-set function, expecting a node-set as an argument, and pattern expressions return node-sets. The node-set acted upon in this example is the set of <month> elements descended from <harvest>. Because ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Beginning XSLT and XPath: Transforming XML Documents and Data

Beginning XSLT and XPath: Transforming XML Documents and Data

Ian Williams
Java and XSLT

Java and XSLT

Eric M. Burke
Learning XSLT

Learning XSLT

Michael Fitzgerald

Publisher Resources

ISBN: 0130404462Purchase book