Name
xs:group(definition) — Global elements group declaration that can be referenced within the same schema by other schemas.
Synopsis
<xs:group
name = xs:NCName
>
Content: (xs:annotation?, (xs:all | xs:choice | xs:sequence))
</xs:group>
May be included in: xs:redefine, xs:schema
Description
Groups of elements can be globally defined and used as containers, which can be referenced elsewhere in this schema or in other schemas. These containers, which are almost free of semantics, are very flexible and may be used as building blocks for the definition of local or global complex types.
Being global components, they can also be used to encapsulate element
definitions that cannot be made global, such as unqualified elements
in a schema with target namespaces, multiple elements with the same
name in a schema, elements that should not be used as document
elements, or elements that should be redefined through
xs:redefine in other schemas.
Element groups can be redefined through
xs:redefine; the redefinition can be either a
restriction (similar to a complex type derivation by restriction) or
an extension. (This is more flexible than a complex type extension
since the location where the base group is included in the new group
can be chosen, while the new elements are always located after the
base type during a derivation by extension.)
Any of the three compositors (xs:all,
xs:sequence, or xs:choice) may
be used to create an element group.
Restrictions
When a group is created using a xs:all