<?xml version='1.0'?> 
<!DOCTYPE schema PUBLIC '-//W3C//DTD XSDL 19990506//EN' 
                        'http://www.w3.org/1999/05/06-xsdl/WD-xsdl.dtd'>

<schema xmlns='http://www.w3.org/TR/1999/WD-xdtl-19990506.xsd'
        name='http://www.w3.org/TR/1999/WD-xdtl-19990506.xsd'
        version='0.1'>
<modelGroup name="ordered">
   <choice>
      <modelGroupRef name="bounds"/>
      <modelGroupRef name="numeric"/>
   </choice>
</modelGroup>
<modelGroup name="bounds">
   <choice>
      <sequence>
         <elementTypeRef name="minInclusive" minOccur="0" maxOccur="1"/>
         <elementTypeRef name="maxInclusive" minOccur="0" maxOccur="1"/>
      </sequence>
      <sequence>
         <elementTypeRef name="minExclusive" minOccur="0" maxOccur="1"/>
         <elementTypeRef name="maxExclusive" minOccur="0" maxOccur="1"/>
      </sequence>
   </choice>
</modelGroup>
<modelGroup name="numeric">
   <choice>
      <elementTypeRef name="precision"/>
      <elementTypeRef name="scale"/>
   </choice>
</modelGroup>
<modelGroup name="unordered">
   <choice>
      <modelGroupRef name="lexicalRepresentation"/>
      <modelGroupRef name="enumeration"/>
      <modelGroupRef name="length"/>
      <modelGroupRef name="maxLength"/>
   </choice>
</modelGroup>

<elementType name="datatype">
   <sequence>
      <elementTypeRef name="basetype"/>
      <choice minOccur="0" maxOccur="*">
         <modelGroupRef name="ordered"/>
         <modelGroupRef name="unordered"/>
      </choice>
   </sequence>
   <attrDecl name="name" required="true">
      <datatypeRef name="NMTOKEN"/>
   </attrDecl>
   <attrDecl name="export">
      <datatypeRef name="boolean">
         <default>true</default>
      </datatype>
   </attrDecl> 
</elementType>
<elementType name="basetype">
   <empty/>
   <attrDecl name="name" required="true">
      <datatypeRef name="NMTOKEN"/>
   </attrDecl>
   <attrDecl name="schemaAbbrev"> 
      <datatypeRef name="NMTOKEN"/> 
   </attrDecl>
   <attrDecl name="schemaName">
      <datatypeRef name="uri"/>
   </attrDecl>
</elementType>
<elementType name="maxExclusive">
   <datatypeRef name="string"/> <!-- the datatype depends on the basetype -->
</elementType>
<elementType name="minExclusive">
   <datatypeRef name="string"/> <!-- the datatype depends on the basetype -->
</elementType>
<elementType name="maxInclusive">
   <datatypeRef name="string"/> <!-- the datatype depends on the basetype -->
</elementType>
<elementType name="minInclusive">
   <datatypeRef name="string"/> <!-- the datatype depends on the basetype -->
</elementType>
<elementType name="precision">
   <datatypeRef name="integer"/>
</elementType>
<elementType name="scale">
   <datatypeRef name="integer"/>
</elementType>
<elementType name="length">
   <datatypeRef name="integer"/>
</elementType>
<elementType name="maxLength">
   <datatypeRef name="integer"/>
</elementType>
<elementType name="enumeration">
   <sequence minOccur="1" maxOccur="*">
      <elementTypeRef name="literal"/>
   </sequence>
</elementType>
<elementType name="literal">
   <datatypeRef name="string"/>  <!-- the datatype depends on the basetype -->
</elementType>
<elementType name="lexicalRepresentation">
   <sequence minOccur="1" maxOccur="*">
      <elementTypeRef name="lexical"/>
   </sequence>
</elementType>
<elementType name="lexical">
   <datatypeRef name="string"/>  <!-- the datatype depends on the basetype -->
</elementType>
</schema>
