<schema
  xmlns='http://www.w3.org/2000/10/XMLSchema'
  targetNamespace='http://www.w3.org/namespace/'
  xmlns:t='http://www.w3.org/namespace/'>

 <element name='cdl-list'>
  <complexType>
   <sequence maxOccurs='unbounded'>
    <element ref='t:cdl'/>
   </sequence>
  </complexType>
 </element>

 <element name='cdl'>
  <complexType>
   <choice maxOccurs='unbounded'>
    <element ref='t:comp'/>
    <element ref='t:stroke'/>
   </choice>
   <attribute name='char' type='string' use='optional'/>
   <attribute name='uni' type='string' use='optional'/>
   <attribute name='variant' type='string' use='optional'/>
   <attribute name='points' type='string' use='optional'/>
   <attribute name='radical' type='string' use='optional'/>
  </complexType>
 </element>

 <element name='comp'>
  <complexType>
   <attribute name='char' type='string' use='optional'/>
   <attribute name='uni' type='string' use='optional'/>
   <attribute name='variant' type='string' use='optional'/>
   <attribute name='points' type='string' use='optional'/>
   <attribute name='transform' type='string' use='optional'/>
   <attribute name='stroke-order' type='string' use='optional'/>
  </complexType>
 </element>

 <element name='stroke'>
  <complexType>
   <attribute name='type' type='string' use='optional'/>
   <attribute name='points' type='string' use='optional'/>
   <attribute name='head' use='optional'>
    <simpleType>
     <restriction base='string'>
      <enumeration value='normal'/>
      <enumeration value='cut'/>
      <enumeration value='corner'/>
      <enumeration value='vertical'/>
     </restriction>
    </simpleType>
   </attribute>
   <attribute name='tail' use='optional'>
    <simpleType>
     <restriction base='string'>
      <enumeration value='normal'/>
      <enumeration value='cut'/>
      <enumeration value='long'/>
     </restriction>
    </simpleType>
   </attribute>
  </complexType>
 </element>
</schema>
