XPath and XPointer. Locating Content in XML Documents - Helion
ISBN: 978-05-965-5210-7
stron: 210, Format: ebook
Data wydania: 2002-07-31
Księgarnia: Helion
Cena książki: 84,92 zł (poprzednio: 98,74 zł)
Oszczędzasz: 14% (-13,82 zł)
Referring to specific information inside an XML document is a little like finding a needle in a haystack: how do you differentiate the information you need from everything else? XPath and XPointer are two closely related languages that play a key role in XML processing by allowing developers to find these needles and manipulate embedded information. XPath describes a route for finding specific items by defining a path through the hierarchy of an XML document, abstracting only the information that's relevant for identifying the data. XPointer extends XPath to identify more complex parts of documents. The two technologies are critical for developers seeking needles in haystacks in various types of processing.XPath and XPointer fills an essential need for XML developers by focusing directly on a critical topic that has been covered only briefly. Written by John Simpson, an author with considerable XML experience, the book offers practical knowledge of the two languages that underpin XML, XSLT and XLink. XPath and XPointer cuts through basic theory and provides real-world examples that you can use right away.Written for XML and XSLT developers and anyone else who needs to address information in XML documents, the book assumes a working knowledge of XML and XSLT. It begins with an introduction to XPath basics. You'll learn about location steps and paths, XPath functions and numeric operators. Once you've covered XPath in depth, you'll move on to XPointer--its background, syntax, and forms of addressing. By the time you've finished the book, you'll know how to construct a full XPointer (one that uses an XPath location path to address document content) and completely understand both the XPath and XPointer features it uses.XPath and XPointer contains material on the forthcoming XPath 2.0 spec and EXSLT extensions, as well as versions 1.0 of both XPath and XPointer. A succinct but thorough hands-on guide, no other book on the market provides comprehensive information on these two key XML technologies in one place.
Osoby które kupowały "XPath and XPointer. Locating Content in XML Documents", wybierały także:
- Flash i Wallaby. Projektowanie animacji zgodnych z HTML5 24,69 zł, (7,90 zł -68%)
- API nowoczesnej strony WWW. Usługi sieciowe w PHP 32,90 zł, (16,45 zł -50%)
- XML. Szybki start. Wydanie II 49,00 zł, (24,50 zł -50%)
- XML. Tworzenie stron WWW z wykorzystaniem XML, CSS, XHTML oraz XSLT. Niebieski podręcznik 49,00 zł, (24,50 zł -50%)
- Java i XML. Wydanie III 57,00 zł, (28,50 zł -50%)
Spis treści
XPath and XPointer. Locating Content in XML Documents eBook -- spis treści
- XPath and XPointer
- SPECIAL OFFER: Upgrade this ebook with OReilly
- A Note Regarding Supplemental Files
- Preface
- Who Should Read This Book?
- Who Should Not Read This Book?
- Organization of the Book
- Conventions Used in This Book
- Comments and Questions
- Acknowledgments
- 1. Introducing XPath and XPointer
- 1.1. Why XPath and XPointer?
- 1.2. Antecedents/History
- 1.2.1. DSSSL
- 1.2.2. XSL
- 1.2.3. TEI
- 1.2.4. Intermedia
- 1.3. XPath, XPointer, and Other XML-Related Specs
- 1.3.1. Specs Dependent on XPath and XPointer
- 1.4. XPath and XPointer Versus XQuery
- 2. XPath Basics
- 2.1. The Node Tree: An Introduction
- 2.2. XPath Expressions
- 2.2.1. Location Steps and Location Paths
- 2.2.2. Expression Syntax
- 2.2.2.1. Tokens
- 2.2.2.2. Delimiters
- 2.2.2.3. Combining tokens and delimiters into complete expressions
- 2.3. XPath Data Types
- 2.3.1. Strings
- 2.3.2. Numeric Values
- 2.3.3. Boolean Values
- 2.4. Nodes and Node-Sets
- 2.4.1. Node Properties
- 2.4.1.1. Node names
- 2.4.1.2. Document order
- 2.4.1.3. Family relationships
- 2.4.2. Node-Sets
- 2.4.3. Node Types
- 2.4.3.1. The root node
- 2.4.3.2. Element nodes
- 2.4.3.3. Attribute nodes
- 2.4.3.4. PI nodes
- 2.4.3.5. Comment nodes
- 2.4.3.6. Text nodes
- 2.4.3.7. Namespace nodes
- 2.4.3.8. XPath node types and the XML Infoset
- 2.4.1. Node Properties
- 2.5. Node-Set Context
- 2.6. String-Values
- 2.6.1. String-Value of a Node-Set
- 3. Location Steps and Paths
- 3.1. XPath Expressions
- 3.1.1. The Filesystem Analogy
- 3.1.2. Points of Similarity, Points of Difference
- 3.2. Location Paths
- 3.2.1. The Importance of Context
- 3.2.2. Absolute Versus Relative Location Paths
- 3.2.3. Compound Location Paths
- 3.3. Location Steps
- 3.3.1. The Big Picture
- 3.3.2. The Node Test
- 3.3.3. The Axis
- 3.3.3.1. Defaults and shortcuts
- 3.3.3.2. Restrictions by context node type
- 3.3.3.3. Axes and efficiency
- 3.3.4. The Predicate
- 3.3.4.1. Nesting predicates
- 3.3.4.2. Compound predicates
- 3.3.4.3. Predicates with a single value and no operator
- 3.3.4.4. Special case: numeric-valued predicates
- 3.3.4.5. "Stacked" predicates
- 3.4. Compound Location Paths Revisited
- 3.1. XPath Expressions
- 4. XPath Functions and Numeric Operators
- 4.1. Introduction to Functions
- 4.1.1. What Functions Do
- 4.1.2. Functions Within Functions
- 4.2. XPath Function Types
- 4.2.1. Node-Set Functions
- 4.2.1.1. last( )
- 4.2.1.2. position( )
- 4.2.1.3. count(nodeset)
- 4.2.1.4. id(anytype)
- 4.2.1.5. id( ) and node-set arguments
- 4.2.1.6. local-name(nodeset?)
- 4.2.1.7. namespace-uri(nodeset?)
- 4.2.1.8. name(nodeset?)
- 4.2.2. String Functions
- 4.2.2.1. string(anytype?)
- 4.2.2.2. concat(string1, string2, ...)
- 4.2.2.3. starts-with(string1, string2)
- 4.2.2.4. contains(string1, string2)
- 4.2.2.5. substring(string, number1, number2?)
- 4.2.2.6. substring-before(string1, string2) and substring-after(string1, string2)
- 4.2.2.7. string-length(string?)
- 4.2.2.8. normalize-space(string?)
- 4.2.2.9. translate(string1, string2, string3)
- 4.2.3. Boolean Functions
- 4.2.3.1. boolean(anytype)
- 4.2.3.2. not(boolean)
- 4.2.3.3. true() and false( )
- 4.2.3.4. lang(string)
- 4.2.4. Numeric Functions
- 4.2.4.1. number(anytype?)
- 4.2.4.2. sum(nodeset)
- 4.2.4.3. floor(number) and ceiling(number)
- 4.2.4.4. round(number)
- 4.2.1. Node-Set Functions
- 4.3. XPath Numeric Operators
- 4.3.1. div
- 4.3.2. mod
- 4.1. Introduction to Functions
- 5. XPath in Action
- 5.1. XPath Visualiser: Some Background
- 5.2. Sample XML Document
- 5.3. General to Specific, Common to Far-Out
- 5.3.1. The Node Test
- 5.3.2. Axes
- 5.3.3. Predicates
- 5.3.4. Functions
- 5.3.5. Sublimely Ridiculous
- 6. XPath 2.0
- 6.1. General Goals
- 6.1.1. Simplify Manipulation of XML Schema-Typed Content
- 6.1.2. Simplify Manipulation of String Content
- 6.1.3. Support Related XML Standards
- 6.1.4. Improve Ease of Use
- 6.1.5. Improve Interoperability
- 6.1.6. Improve i18n Support
- 6.1.7. Maintain Backward Compatibility
- 6.1.8. Enable Improved Processor Efficiency
- 6.2. Specific Requirements
- 6.2.1. XPath 2.0 MUSTs
- 6.2.1.1. Express its data model in terms of the XML Infoset (1.1)
- 6.2.1.2. Provide common core syntax and semantics for XSLT and XML Query (1.2)
- 6.2.1.3. Support explicit "for any" and "for all" Boolean operations (1.3)
- 6.2.1.4. Extend the existing set of aggregate functions (1.4)
- 6.2.1.5. Loosen restrictions on location steps (2.1)
- 6.2.1.6. Provide a conditional expression (2.2)
- 6.2.1.7. Define consistent implicit semantics for collection-valued subexpressions (2.3)
- 6.2.1.8. Support string matching with regular expressions (3)
- 6.2.1.9. Define the operator matrix and conversions (4.1)
- 6.2.1.10. Allow scientific notation for numbers (4.2)
- 6.2.1.11. Define cast and constructor functions (4.3)
- 6.2.1.12. Support accessing the simple-type values of elements and attributes (4.5)
- 6.2.1.13. Define the behavior of operators for null arguments (4.6)
- 6.2.2. XPath 2.0 SHOULDs
- 6.2.2.1. Maintain backward compatibility with XPath 1.0 (1.5)
- 6.2.2.2. Provide intersection and difference functions (1.6)
- 6.2.2.3. Support the unary plus operator (1.7)
- 6.2.2.4. Simplify string replacement (2.4.1)
- 6.2.2.5. Simplify string padding (2.4.2)
- 6.2.2.6. Simplify string case conversions (2.4.3)
- 6.2.2.7. Support aggregation functions over collection-valued expressions (2.5)
- 6.2.2.8. Add a "list" data type (4.4)
- 6.2.2.9. Select elements/attributes based on an explicit XML Schema type (5.1)
- 6.2.2.10. Select elements/attributes based on an XML Schema type hierarchy (5.2)
- 6.2.2.11. Select elements based on XML Schema substitution groups (5.3)
- 6.2.2.12. Support lookups based on XML Schema unique constraints and keys (5.4)
- 6.2.1. XPath 2.0 MUSTs
- 6.1. General Goals
- 7. XPointer Background
- 7.1. XPointer and Media types
- 7.2. Some Definitions
- 7.2.1. Resource
- 7.2.2. Subresource
- 7.2.3. Location
- 7.2.4. Location-set
- 7.2.5. Point
- 7.2.6. Range
- 7.2.7. Points and Ranges: Flattening the Logical Hierarchy
- 7.3. The Framework
- 7.4. Error Types
- 7.4.1. Syntax Errors
- 7.4.2. Resource Errors
- 7.4.3. Subresource Errors
- 7.5. Encoding and Escaping Characters in XPointer
- 7.5.1. Characters Significant to XPointer Itself
- 7.5.2. URI-Significant Characters
- 7.5.2.1. URIs versus IURIs
- 7.5.3. Characters in XML Documents
- 7.5.4. Progressive Escaping
- 7.5.4.1. Progressive escaping: a (perverse) example
- 8. XPointer Syntax
- 8.1. Shorthand Pointers
- 8.2. Scheme-Based XPointer Syntax
- 8.2.1. The Scheme
- 8.2.2. The schemedata
- 8.2.3. Contents of the xmlns() Scheme
- 8.2.4. Contents of the element( ) Scheme
- 8.2.5. Combining Names and Child Sequences
- 8.2.6. Contents of the xpointer( ) Scheme
- 8.2.7. Custom Schemes
- 8.2.8. Multiple Pointer Parts
- 8.2.8.1. "Failure-proofing" XPointers
- 8.2.8.2. Declaring and using namespaces
- 8.2.8.3. Mixing it up
- 8.3. Using XPointers in a URI
- 9. XPointer Beyond XPath
- 9.1. Why Extend XPath?
- 9.2. Points and Ranges
- 9.2.1. Points
- 9.2.1.1. Node points versus character points
- 9.2.1.2. Point syntax
- 9.2.1.3. Points as "nodes"
- 9.2.1.4. Points and general entities
- 9.2.2. Ranges
- 9.2.2.1. What can be in a range
- 9.2.2.2. Range syntax
- 9.2.2.3. Ranges as "nodes"
- 9.2.2.4. Covering ranges
- 9.2.1. Points
- 9.3. XPointer Extensions to Document Order
- 9.3.1. XPointer Document Order Extensions: Examples
- 9.4. XPointer Functions
- 9.4.1. start-point(locset)
- 9.4.2. end-point(locset)
- 9.4.3. range-to(locset)
- 9.4.4. string-range(locset, string, number1?, number2?)
- 9.4.5. range(locset)
- 9.4.6. range-inside(locset)
- 9.4.7. here( )
- 9.4.8. origin( )
- A. Extension Functions for XPath in XSLT
- A.1. Additional Functions in XSLT 1.0
- A.2. EXSLT Extensions
- A.2.1. EXSLT Functions Module
- A.2.2. EXSLT Dates-and-Times Module
- A.2.3. EXSLT Dynamic Module
- A.2.4. EXSLT Common Module
- A.2.5. EXSLT Math Module
- A.2.6. EXSLT Regular Expressions Module
- A.2.7. EXSLT Sets Module
- A.2.8. EXSLT Strings Module
- Colophon
- SPECIAL OFFER: Upgrade this ebook with OReilly