<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.nexml.org/2009"
    xmlns:sawsdl="http://www.w3.org/ns/sawsdl" xmlns="http://www.nexml.org/2009"
    elementFormDefault="qualified">
    <xs:annotation>
        <xs:documentation>
            This module defines complex types for <a href="#Taxon">OTU</a>
            objects and their <a href="#Taxa">container objects</a>. These
            types are analogous to the "taxa" block in NEXUS files. They
            are used in the nexml schema, and in instance documents, to 
            normalize the cardinality between nodes in trees and rows in
            matrices.
        </xs:documentation>
    </xs:annotation>
    <xs:include schemaLocation="../abstract.xsd"/>
    <xs:include schemaLocation="../meta/sets.xsd"/>
    <!-- 
        The following type definitions build up a taxa block  
    -->

    <!-- Otu data type -->
    <xs:complexType name="Taxon"
        sawsdl:modelReference="http://evolutionaryontology-dev.nescent.org/cdao.owl#TU">
        <xs:complexContent>
            <xs:extension base="IDTagged"/>
        </xs:complexContent>
    </xs:complexType>

    <!-- Otus data type -->
    <xs:complexType name="Taxa">
        <xs:complexContent mixed="false">
            <xs:extension base="IDTagged">
                <xs:sequence>
                    <xs:element name="otu" type="Taxon" minOccurs="0" maxOccurs="unbounded"/>
                    <xs:element name="set" type="TaxonSet" minOccurs="0" maxOccurs="unbounded"/>
                </xs:sequence>                
            </xs:extension>            
        </xs:complexContent>        
    </xs:complexType>

</xs:schema>
