June 2002
Intermediate to advanced
396 pages
11h 8m
English
xs:choice(within a group) — Compositor to define group of mutually exclusive elements or compositors. The number of occurrences cannot be defined when xs:choice is used within a group.
<xs:choice
id = xs:ID
{any attributes with non-schema namespace}
>
Content: (xs:annotation?, (xs:element | xs:group | xs:choice |
xs:sequence | xs:any)
)*)
</xs:choice>
May be included in: xs:group (definition)
When embedded in a group definition, the xs:choice
compositor has the same function as other contexts, except that the
number of its occurrences is defined in the
xs:group reference instead of by the
minOccurs and maxOccurs
attributes of the xs:choice compositor.
The minOccurs and maxOccurs
attributes that are allowed in other contexts are forbidden.
<xs:group name="author-or-character">
<xs:choice>
<xs:element ref="author"/>
<xs:element ref="character"/>
</xs:choice>
</xs:group>id
W3C XML Schema’s element ID.