xs:union

Element Information

Model

Attributes

QName Type Fixed Default Use Inheritable Annotation
id xs:ID optional
memberTypes xs:null optional
Wildcard: ANY attribute from ANY namespace OTHER than 'http://www.w3.org/2001/XMLSchema'

Used By

Element Group xs:simpleDerivation

Source

<xs:element name="union" id="union">
  <xs:complexType>
    <xs:annotation>
      <xs:documentation source="http://www.w3.org/TR/xmlschema-2/#element-union">memberTypes attribute must be non-empty or there must be at least one simpleType child</xs:documentation>
    </xs:annotation>
    <xs:complexContent>
      <xs:extension base="xs:annotated">
        <xs:sequence>
          <xs:element name="simpleType" type="xs:localSimpleType" minOccurs="0" maxOccurs="unbounded"/>
        </xs:sequence>
        <xs:attribute name="memberTypes" use="optional">
          <xs:simpleType>
            <xs:list itemType="xs:QName"/>
          </xs:simpleType>
        </xs:attribute>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
</xs:element>

Sample