O'Reilly logo

Definitive XML Schema, Second Edition by Priscilla Walmsley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 14. Assertions

image

Assertions are a powerful new feature in 1.1 that allows you to specify additional constraints using XPath 2.0. This addresses a significant limitation in XML Schema 1.0 that prevented the definition of co-constraints, where one data item affects the validity of another. It also generally allows for much more complex validation criteria to be expressed.

This chapter covers assertions, as well as conditional type assignment which allows the type of an element to be determined by an XPath expression on its attributes. Conditional type assignment is also new in version 1.1. Although this feature is separate from assertions, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required