<?xml version="1.0"?>
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
            targetNamespace="http://www.castor.org/Test"
            xmlns:cst="http://www.castor.org/Test"
            elementFormDefault="qualified"
            attributeFormDefault="unqualified">

   <!-- Test simpleType definition with union element -->

   <xsd:simpleType name="myUnion">
      <xsd:annotation>
         <xsd:documentation>
              A simpleType definition used for testing Unions
         </xsd:documentation>
      </xsd:annotation>
      <xsd:union memberTypes="cst:string-max8">
         <xsd:annotation>
            <xsd:documentation>A simple Union definition</xsd:documentation>
         </xsd:annotation>
         <xsd:simpleType>
            <xsd:restriction base="xsd:string">
               <xsd:minLength value="4"/>
               <xsd:maxLength value="6"/>
            </xsd:restriction>
         </xsd:simpleType>
      </xsd:union>
   </xsd:simpleType>

   <xsd:simpleType name="string-max8">
      <xsd:restriction base="xsd:string">
         <xsd:minLength value="0"/>
         <xsd:maxLength value="8"/>
      </xsd:restriction>
   </xsd:simpleType>

</xsd:schema>
