<?xml version="1.0" encoding="UTF-8" ?>

<schema xmlns="http://www.w3.org/2001/XMLSchema"
   xmlns:cs="http://www.cs.uct.ac.za/"
   targetNamespace="http://www.cs.uct.ac.za/"
   elementFormDefault="qualified"
   attributeFormDefault="unqualified">

   <annotation>
      <documentation>
         XML Schema for CS Metadata Set
         Hussein Suleman
      </documentation>
   </annotation>

   <element name="cs">
      <complexType>
         <sequence>

            <element name="number" type="integer" minOccurs="1" maxOccurs="1"/>

            <element name="status" minOccurs="1" maxOccurs="1">
               <annotation>
                  <documentation>
                     official  = Official for CSTC and JERIC
                     cofficial = Official for CSTC only
                     jofficial = Official for JERIC only
                     mofficial = Accepted without review
                  </documentation>
               </annotation>
               <simpleType>
                  <restriction base="string">
                     <enumeration value="official"/>
                     <enumeration value="cofficial"/>
                     <enumeration value="jofficial"/>
                     <enumeration value="proposed"/>
                     <enumeration value="cproposed"/>
                     <enumeration value="jproposed"/>
                     <enumeration value="mofficial"/>
                     <enumeration value="rejected"/>
                  </restriction>
               </simpleType>
            </element>

            <element name="contributor" minOccurs="1" maxOccurs="1">
               <complexType>
                  <sequence>
                     <element name="first_name" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="last_name" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="email" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="institution" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="department" type="string" minOccurs="0" maxOccurs="1"/>
                  </sequence>
               </complexType>
            </element>
            
            <element name="title" type="string" minOccurs="1" maxOccurs="1"/>
            
            <element name="date" type="date" minOccurs="1" maxOccurs="1"/>
            
            <element name="author" minOccurs="0" maxOccurs="unbounded">
               <complexType>
                  <sequence>
                     <element name="first_name" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="last_name" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="email" type="string" minOccurs="0" maxOccurs="1"/>
                  </sequence>
               </complexType>
            </element>
            
            <element name="category" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="subject" minOccurs="0" maxOccurs="unbounded">
               <complexType>
                  <sequence>
                     <element name="subject" type="string" minOccurs="1" maxOccurs="1"/>
                     <element name="sub_subject" type="string" minOccurs="1" maxOccurs="1"/>
                  </sequence>
               </complexType>
            </element>
            
            <element name="curriculum" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="language" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="programming_lang" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="operating_system" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="platform" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="multimedia_content" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="tools" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="publisher" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="acknowledgements" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="source" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="rights" type="string" minOccurs="0" maxOccurs="unbounded"/>

            <element name="file" minOccurs="0" maxOccurs="unbounded">
               <complexType>
                  <sequence>
                     <element name="url" type="anyURI" minOccurs="1" maxOccurs="1"/>
                     <element name="description" type="string" minOccurs="0" maxOccurs="1"/>
                     <element name="size" type="integer" minOccurs="0" maxOccurs="1"/>
                  </sequence>
               </complexType>
            </element>
         
         </sequence>
      </complexType>
   </element>

</schema>



