Chapter 4. XPath Expressions
Expressions
Location Path
Patterns
Axes, node test, and predicate
Position()
Abbreviations
XPath enables you to access parts of an XML document instance using “family affair” navigation relationships like ancestor, descendant, parent, child, and sibling. It provides the processor-readable (and human-readable) syntax for doing this, in the form of expressions.
In Chapter 1, we identified the tree structure by which XML addresses nodes in a document. In this chapter, we will explain the use of expressions, in the form of patterns and location paths, as well as location steps within those paths. We begin with the basic concepts of XPath, the XPath syntax and concepts like document order, context, and proximity. Chapter 5 ...
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.
Read now
Unlock full access