From Amazon
In four parts, the first part introduces XML and covers the fundamentals, including chapters on Document Type Definitions, Namespaces, and Internationalisation. The next part focuses on XML as a document format, with coverage of XHTML, XSL transformations, XPath, XLinks and XPointer, and using CSS (Cascading Stylesheets) or XSL-FO (XSL Formatting Objects). Data transmission and programming are the focus of the third part, which explains the Document Object Model and introduces SAX (the Simple API for XML). The final part is the reference section, and covers XML 1.0, XPath, XSLT, DOM, SAX and character sets.
XML is a slippery subject. It is really a family of many related specifications, most of which are still evolving, and in addition most developers need to know about several XML applications alongside the core technology. This handbook sticks mostly to the core of XML, so you should not expect more than a mention of SOAP, SVG (Scaleable Vector Graphics), or MathML, to take three examples. It is disappointing to find hardly any coverage of the XML Schema language.
For what it does cover though, XML in a Nutshell is a masterpiece of compression, laying the foundations for an excellent understanding of XML and finding space for example code and apt comments along the way. --Tim Anderson --This text refers to an alternate Paperback edition.
Review
Book Description
This powerful new edition provides developers with a comprehensive guide to the rapidly evolving XML space. Serious users of XML will find topics on just about everything they need, from fundamental syntax rules, to details of DTD and XML Schema creation, to XSLT transformations, to APIs used for processing XML documents. Simply put, this is the only reference of its kind among XML books.
Whether you're a Web designer using SVG to add vector graphics to web pages, or a C++ programmer using SOAP to serialize objects into a remote database, XML in a Nutshell thoroughly explains the basic rules that all XML documents -- and all XML document creators -- must adhere to, including:
- Essentials of the core XML standards: With this book, you can develop an understanding of well-formed XML, DTDs, namespaces, Unicode, and W3C XML Schema quickly.
- Key technologies used mainly for narrative XML documents such as web pages, books, and articles: You'll gain a working knowledge of XSLT, Xpath, Xlink, Xpointer, CSS, and XSL-FO.
- Technologies for building data-intensive XML applications, and for processing XML documents of any kind: One of the most unexpected developments in XML has been its enthusiastic adoption for structured documents used for storing, and exchanging used by a wide variety of programs. This book will help you understand the tools and APIs needed to write software that processes XML, including the event-based Simple API for XML (SAX2) and the tree-oriented Document Object Model (DOM).
XML in a Nutshell is an essential guide for developers who need to create XML-based file formats and data structures for use in XML documents. This is one book you'll want to close at hand as you delve into XML.
From the Publisher
About the Author
Elliotte Rusty Harold is originally from New Orleans to which he returns periodically in search of a decent bowl of gumbo. However, he currently resides in the University Town Center neighborhood of Irvine with his wife Beth, dog Shayna, and cats Charm (named after the quark) and Marjorie (named after his mother-in-law). He's an adjunct professor of computer science at Polytechnic University where he teaches Java, XML, and object oriented programming. He's a frequent speaker at industry conferences including Software Development, Dr. Dobb's Architecure & Design World, SD Best Practices, Extreme Markup Languages, and too many user groups to count. His open source projects include the XOM Library for processing XML with Java and the Amateur media player.
Excerpt. © Reprinted by permission. All rights reserved.
XPath is a non-XML language for identifying particular parts of XML documents. XPath lets you write expressions that refer to the first person element in a document,the seventh child element of the third person element,the ID attribute of the first person element whose contents are the string "Fred Jones ",all xml-stylesheet processing instructions in the document s prolog,and so forth.XPath indicates nodes by position,relative position,type,content,and several other criteria.
XSLT uses XPath expressions to match and select particular elements in the input document for copying into the output document or further processing.Xpointer uses XPath expressions to identify the particular point in or part of an XML document to which an XLink links.The W3C XML Schema Language uses Xpath expressions to define uniqueness and co-occurrence constraints.XForms relies on XPath to bind form controls to instance data,express constraints on user-entered values,and calculate values that depend on other values.
XPath expressions can also represent numbers,strings,or Booleans.This lets XSLT stylesheets carry out simple arithmetic for purposes such as numbering and cross-referencing figures,tables,and equations.String manipulation in XPath lets XSLT perform tasks such as making the title of a chapter uppercase in a headline or extracting the last two digits from a year.
The Tree Structure of an XML Document
An XML document is a tree made up of nodes.Some nodes contain one or more other nodes.There is exactly one root node,which ultimately contains all other nodes.XPath is a language for picking nodes and sets of nodes out of this tree. From the perspective of XPath,there are seven kinds of nodes:
The root node
Element nodes
Text nodes
Attribute nodes
Comment nodes
Processing-instruction nodes
Namespace nodes
One thing to note are the constructs not included in this list:CDATA sections, entity references,and document type declarations.XPath operates on an XML document after all these items have been merged into the document.For instance, XPath cannot identify the first CDATA section in a document or tell whether a particular attribute value was directly included in the source element start-tag or merely defaulted from the declaration of the element in a DTD.