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 15. Named groups

XML Schema provides the ability to define groups of element and attribute declarations that are reusable by many complex types. Named model groups are fragments of content models, and attribute groups are bundles of attribute declarations that are commonly used together. This chapter explains how to define and reference named model groups and attribute groups.

15.1. Why named groups?

Defining a group and reusing it many times has the advantages of

• Encouraging consistency across schema components

• Allowing the schema author to change multiple content models in only one place

• Making it obvious that certain complex types share similar children or attributes

• In many cases, making the schema less verbose

15.2. Named ...

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