XML Schema Companion

XML Schema Companion

by Neil Bradley




Get powerful results with XML Schema—fast!

The XML Schema Companion brings you up to speed on XML Schema with clarity, thoroughness, and precision. Itis the perfect introduction and reference for every content specialist, architect, and developer...including anyone working with the new schema support in Microsoft Office 2003.

As in his best-selling The XML Companion and The XSL Companion, Neil Bradley carefully organizes this book to fully illuminate the most crucial concepts first. You'll begin by mastering the construction of document models. Next, you'll learn how to define data types that can serve as reusable building blocks for your documents. Then you'll be ready to master the powerful XML Schema pattern language and inheritance techniques. The XML Schema Companion:

  • Carefully explains the essential principles of document modeling with XML Schema
  • Explains how to read and interpret any XML Schema definition
  • Uses practical examples to illuminate schema definition and validation
  • Shows how to resolve schema ambiguities
  • Introduces XML Schema data types simply and precisely
  • Demonstrates how to include external components in schema-conformant documents
  • Presents detailed, practical coverage of namespaces and namespace switching
  • Introduces advanced inheritance techniques for building more flexible, powerful document models
  • Contains an entire chapter of tips for more effective document modeling
  • Includes a complete DTD for XML Schema documents and shows how to create DTD-compatible schemas

Product Details

ISBN-13: 9780321136176
Publisher: Addison-Wesley
Publication date: 11/08/2003
Pages: 336
Product dimensions: 6.60(w) x 8.90(h) x 0.90(d)

About the Author

NEIL BRADLEY is an XML consultant with almost 20 years' practical experience using markup languages. He is an experienced trainer, a regular speaker at industry events, and a contributor to publications such as XML Journal and interChange, the newsletter of the International SGML/XML Users' Group. He is the author of three books on XML and SGML topics published by Addison-Wesley: The XML Companion, Third Edition (2002), The XSL Companion, Second Edition (2002), and The Concise SGML Companion (1997).

Table of Contents


1. Using This Book.

Assumptions. Book Structure. Style Conventions.

Document Models.

2. Essential Concepts.

Well-Formed Documents. Document Classes and Instances. Document Class Rules. Narrative Documents and Data Documents. Example Document Classes. Document Type Definitions. Alternative Modeling Languages. XML Schemas. Data Types.

3. Schema Definitions.

Schema Documents. Annotations. Element and Attribute Declarations. Data Type Definitions. Common Attributes.

4. Validating Document Instances.

Validation Techniques. Namespace Complications. Document Instance Namespace Issues. Schema for Schemas.

5. Simple Elements and Attributes.

Element Declarations. Attribute Declarations.

6. Defining Document Structures.

Document Structures. Child Element References. Complex Type Elements. Sequence of Elements. Optional and Repeating Elements. Choice of Elements. Complex Models. All Elements Required in Any Sequence. The any Element. Shared Groups.

7. Text and Simple Data Types.

Text. Text and Attributes. Mixed Content. Any Element Mixed with Text. Simple Data Types. Special Data Type Features. Nil Values.

8. Ambiguities.

Unequivocal Determination. Serious Ambiguities. Common Solutions. Any Element Ambiguities. Theoretically Trivial Ambiguities.

9. Local Elements.

Global Element Limitations. Local Element Declarations. Context Element Requirement. Sharing Local Elements. Namespace Complications. SGML Exclusions and Inclusions.

10. Global and Shared Attributes.

Global Declarations. Namespace Complications. Attribute Groups.

11. Unique and Referenced Elements.

Unique Fragments and References. Simple DTD-Based Identifiers. Advanced Requirements. Unique Fragment Identification. Fragment Selectors. Scope of Uniqueness. Identifier Fields. Key References. Complete Book Example.

12. Namespace Switching.

Namespace and Schema Relationship. Element Importing. Attribute Importing. Any Element from Other Namespace. Validation Options. Any Attribute from Other Namespace.

13. Including External Components.

Definitions and Documents. Including a Schema Document. Redefining a Schema Document. Importing a Schema Document.

Creating Data Types.

14. Creation of New Simple Types.

Simple Type Definitions. Derivations. Restrictions. Facet Elements. Enumeration Facet. Whitespace and Pattern Facets. Length and Numeric Facets. Derivation of Derivation Limitations. Lists. Unions. Combinations of Unions and Lists. Example Built-in Extended Data Types. String Normalization and Tokens. Type Library.

15. Patterns.

Introduction. Simple Templates. Atoms. Quantifiers and Quantities. Escape Characters. Character Classes. Character Class Ranges. Subexpressions. Character Class Escapes.

16. Shared and Derived Complex Types.

Introduction. Named Complex Types. Additions to the Target Namespace. Derivation from Complex Types. Derivation by Extension. Derivation by Restriction. Simple Content.

17. Advanced Inheritance Techniques.

Inheritance Concepts. Summary of Schema Inheritance Features. Final Types. Fixed Facets. Abstract Data Types. Substitution Data Type Selection. Blocking Derivation Usage. Substitution Elements. Comparison of Java and XML Inheritance Terminology.


18. Document Modeling Techniques.

Industry-Standard Models. Analysis Techniques. Backward Compatibility with a DTD. Element or Attribute Decision. Element Structures. Devising Element and Attribute Names. Comments. Lists. Tables. Representing Special Characters. Schema Document Construction.

19. DTD Models.

Background. Declarations. Element Declarations. Attribute Declarations. Entities for Sharing Definitions. Notations. Suppressed DTD Fragments. Namespace Handling.

20. DTD for Schema Definitions.

Background. Element Hierarchies. Attributes. Complete DTD.

21. Namespaces.

Before Namespaces. The Need for Namespaces. The Namespaces Standard. Namespace Partitions. Namespace Identification. Absence of Namespaces. Namespace Declarations. Default Namespace. Attributes. Combined Qualified and Unqualified Elements. XML Namespace.

22. Next Steps.

Introduction. General XML Sites. Relevant Software. Further Reading. Existing Document Models. Mailing Lists. About the Author.




XML Schemas

The XML Schema Standard is a powerful eXtensible Markup Language (XML) document modeling technology that was released in 2001 by the World Wide Web Consortium and aims to replace the Document Type Definition (DTD) feature of the core XML standard. The XML Schema standard performs the same role and is fully backward compatible in terms of the modeling tools at its disposal, but also includes many additional features.

This book

The XML Schema Companion serves the programmer, analyst, or consultant involved in the modeling of XML documents. It provides a concise, compact yet thorough examination of every feature of the XML Schema standard. It also covers document modeling techniques in general, to assist those who need to amend or create new document models.

This book assumes knowledge of the XML standard in general but does not assume an understanding of the DTD language or any other document modeling language. In addition, it does not require any prior knowledge of namespaces and XPath expressions (they are both exploited to support features of the XML Schema language).

Customer Reviews

Most Helpful Customer Reviews

See All Customer Reviews