<?xml version="1.0"?>
<!-- Change History -->

<!-- 18Dec02 CM -->
<!-- Merged different versions of the BIL Schema.
     This included the new consistent "|" separator,
     and extra TED markup.

   - 01/09/03 PM
   - Changed Image_Stack@ID datatype from integer to token

   - 01/16/03 PM
   - Changed all paragraph-type elements to datatype "string" if they were
   - "token"; token presents too many validation failure possibilities.

   - 01/22/03 PM
   - Changed visibility of some types from owner to delivery

   - 13Feb03 CM
   - Changed visibility=owner for Image_Stack: LUTRef, Subject, and
   - File_Naming_Convention inside of Series/Z_Series,Series/T_Series, etc.

   - 02/19/03 PM
   - added action markup to entityRefs

   - 02/20/03 PM
   - added asynch markup to deliverables
   
   - 02/26/03 PM
   - added asynchAction markup to stack urns

   - 04/03/03 PM
   - Removed bil namespace declaration and target namespace, for compatibility
     with schema in Tamino
	xmlns:bil="http://hul.harvard.edu/ois/xml/ns/bil/BILSchema.html"
	targetNamespace="http://hul.harvard.edu/ois/xml/ns/bil/BILSchema.html"

   - 06/04/03 PM
   - Added xs: prefix to XSchema namespace, and removed bil: prefix, for
      compatibility with previous change (should have been done before)		
-->

<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
	xmlns:ted="http://hul.harvard.edu/ois/xml/ns/ted/TEDSchema.html"
	elementFormDefault="qualified"
	version="1.1"
	ted:doctype="/Project"
	ted:searchindex="Project|."
	ted:advancedsearchboolean="2"
	ted:advancedsearchindex="Anywhere|.,Subject|Project_Description/Subject~='?' or Datasets//Subject~='?',Persons|Principal_Investigator/Name~='?' or Co-Investigator/Name~='?' or Datasets//Creator~='?',Project_Description|Project_Description/Title~='?' or Project_Description/Abstract,Instrument_Information|Instrument_Setup,Preparation|Preparation,Support|Project_Description/Support/@Title~='?' or Project_Description/Support/@ID~='?' or Project_Description/Support/@Funding_Organization~='?'"
	ted:limitbyvalue=""
	ted:limitbyvalueLabel=""
	ted:limitbyexistence="Preparation|Fluorescence_Microscopy,Instrument_Setup|Confocal_Microscope"
	ted:limitbyexistenceLabel=""
	ted:browseindex="Subject|/Project/Project_Description/Subject | /Project/Datasets//Subject,Persons|/Project/Principal_Investigator/Name | /Project/Co-Investigator/Name | /Project/Datasets//Creator"
	ted:browsexpath="Subject|//Subject~='?',Persons|Principal_Investigator/Name~='?' or Co-Investigator/Name~='?' or Datasets//Creator~='?'"
	ted:resultsdisplay="Title|/Project/Project_Description/Title, Abstract|/Project/Project_Description/Abstract, Date|/Project/Project_Description/@Submitted_Date, Principal Investigator|/Project/Principal_Investigator/Name, ino:id|/Project/@ino:id"
	ted:recorddisplay="Project|/Project/Project_Description/Title, Abstract|/Project/Project_Description/Abstract, Subject|/Project/Project_Description/Subject, Dataset Name|/Project/Datasets/Subgroup/Name, Image Stack|/Project/Datasets/Subgroup/Image_Stack/Path, Series|/Project/Datasets/Subgroup/Image_Stack/Series/Path"
	ted:saverecord="/Project,/Project/Datasets//Image_Stack"
  ted:defaultSave="/Project/Project_Description/Title,/Project/Project_Description/Abstract"
  ted:instanceLabel="/Project/Project_Description/Title"
	ted:saveresults="Project|/Project"
        ted:defaultRecordDisplay="displayHits"
>

<xs:element name="Project">
 <xs:complexType>
  <xs:sequence>
   <xs:element name="Project_Description" type="Project_Description" ted:page="new"/>
   <xs:element name="Site" type="Site" maxOccurs="unbounded" ted:page="new"/>
   <xs:element name="Principal_Investigator" type="Investigator" ted:page="new"/>
   <xs:element name="Co-Investigator" type="Investigator" minOccurs="0" maxOccurs="unbounded" ted:page="new"/>
   <xs:element name="Publication" type="Publication" minOccurs="0" maxOccurs="unbounded" ted:page="new"/>
   <xs:element name="Preparation" type="Preparation" maxOccurs="unbounded" ted:page="new"/>
   <xs:element name="Instrument_Setup" type="Instrument" maxOccurs="unbounded" ted:page="new"/>
   <xs:element name="Datasets" ted:page="new" ted:view="swingStructureView" ted:form="StructureSection">
    <xs:complexType>
     <xs:sequence>
      <xs:element name="Subgroup" type="Subgroup" minOccurs="0"
      maxOccurs="unbounded" ted:form="StructureSection" ted:asynch="div" ted:asynchDivName="Name"/>
      <xs:element name="Image_Stack" type="Image_Stack" minOccurs="0"
      maxOccurs="unbounded" ted:page="new" ted:form="StructureSection"/>
      <xs:element name="Path" type="xs:token" ted:visibility="owner" ted:textColumns="40"/>
      <xs:element name="Lookup_Table" type="LUT" minOccurs="0"
      maxOccurs="unbounded" ted:form="LutSection"/>
     </xs:sequence>
    </xs:complexType>
   </xs:element>
  </xs:sequence>
 </xs:complexType>
<!--
   <xs:keyref name="SiteKeyref" refer="SiteKey">
  <xs:selector xpath="//SiteRef"/>
  <xs:field xpath="@ID"/>
 </xs:keyref>
 <xs:key name="SiteKey">
  <xs:selector xpath="//Site"/>
  <xs:field xpath="@ID"/>
 </xs:key>
 <xs:keyref name="PreparationKeyref" refer="PreparationKey">
  <xs:selector xpath="//PreparationRef"/>
  <xs:field xpath="@ID"/>
 </xs:keyref>
 <xs:key name="PreparationKey">
  <xs:selector xpath="//Preparation"/>
  <xs:field xpath="@ID"/>
 </xs:key>
 <xs:keyref name="InstrumentKeyref" refer="InstrumentKey">
  <xs:selector xpath="//InstrumentRef"/>
  <xs:field xpath="@ID"/>
 </xs:keyref>
 <xs:key name="InstrumentKey">
  <xs:selector xpath="//Instrument_Setup"/>
  <xs:field xpath="@ID"/>
 </xs:key>
 <xs:keyref name="LUTKeyref" refer="LUTKey">
  <xs:selector xpath="//LUTRef"/>
  <xs:field xpath="@ID"/>
 </xs:keyref>
 <xs:key name="LUTKey">
  <xs:selector xpath="//Lookup_Table"/>
  <xs:field xpath="@ID"/>
 </xs:key>
-->
</xs:element> <!-- END PROJECT ELEMENT -->

<xs:complexType name="EntityRef">
 <xs:sequence>
 </xs:sequence>
 <xs:attribute name="ID" type="xs:integer" use="required" ted:entityKey="primaryRef" ted:visibility="owner"/>
 <xs:attribute name="Name" type="xs:token" ted:entityKey="identifierRef"/>
</xs:complexType>

<xs:complexType name="Project_Description">
 <xs:sequence>
   <xs:element name="Title" type="xs:token" ted:textColumns="50"/>
   <xs:element name="Abstract" type="xs:string" ted:textRows="10" ted:textColumns="50"/>
   <xs:element name="Subject" type="xs:token" maxOccurs="unbounded" ted:visibility="delivery"/>
   <xs:element name="Support" type="Support" minOccurs="0" maxOccurs="unbounded"/>
   <xs:element name="Erratum" type="xs:string" minOccurs="0" maxOccurs="unbounded" ted:visibility="delivery"/>
 </xs:sequence>
 <xs:attribute name="projectID" type="xs:token" use="required" />
 <xs:attribute name="Schema_Version" type="xs:string" use="required" ted:textColumns="5" ted:visibility="system"/>
   <xs:attribute name="Submitted_Date" type="xs:date" use="required"
   ted:visibility="delivery" ted:helpText="YYYY-MM-DD"/>
   <xs:attribute name="Accepted_Date" type="xs:date" ted:visibility="owner"/>
   <xs:attribute name="Last_Modified_Date" type="xs:date" use="required" ted:visibility="delivery"/>
</xs:complexType>

<xs:complexType name="Investigators">
 <xs:sequence>
  <xs:element name="Principal_Investigator" type="Investigator"/>
  <xs:element name="Co-Investigator" type="Investigator" minOccurs="0" maxOccurs="unbounded"/>
 </xs:sequence>
</xs:complexType>

<xs:complexType name="Investigator">
  <xs:sequence>
   <xs:element name="Name" type="xs:token"/>
   <xs:element name="Email" type="xs:token"/>
   <xs:element name="SiteRef" type="EntityRef" ted:label="Site"
  ted:entityRef="Site" ted:action="replaceRef"/>
  </xs:sequence>
</xs:complexType>

<!--
  Site does not get folded into the Investigator element, b/c over time,
  investigators will appear at different sites.
-->
<!-- The Site_Identifier attribute is intended to be used in SiteRefs for human
interpretation; we don't enforce integrity constraints on it, but it is intended
to aid the interpretation of ID's. We require every Site to have an identifier,
but don't require the Ref's to have one, but that is preferred. -->
<xs:complexType name="Site">
 <xs:sequence>
   <xs:element name="Department" type="xs:token"/>
   <xs:element name="Institution" type="xs:token"/>
   <xs:element name="Address_Line_1" type="xs:token"/>
   <xs:element name="Address_Line_2" type="xs:token" minOccurs="0"/>
   <xs:element name="Address_Line_3" type="xs:token" minOccurs="0"/>
   <xs:element name="City" type="xs:token"/>
   <xs:element name="State" type="xs:token" minOccurs="0"/>
   <xs:element name="Postal_Code" type="xs:token"/>
   <xs:element name="Country" type="xs:token"/>
  </xs:sequence>
  <xs:attribute name="ID" type="xs:integer" use="required" ted:visibility="owner" ted:entityKey="primaryAuto"/>
  <xs:attribute name="Site_Identifier" type="xs:token" use="required"
  ted:entityKey="identifier" ted:helpText="Your shorthand for this site"/>
</xs:complexType>

<xs:complexType name="Preparation">
 <xs:annotation>
  <xs:documentation>
   In order to add a new type of preparation, you must do two things:
     1. Define a new complex type to represent the preparation type.
     2. Add that element in the choice group, below.
  </xs:documentation>
 </xs:annotation>
  <xs:sequence>
    <xs:choice ted:label="Preparation Type">
     <xs:element name="Fluorescence_Microscopy" type="FM_Preparation"/>
   </xs:choice>
   <xs:element name="Notes" type="xs:string" minOccurs="0" ted:textRows="4" ted:textColumns="40"/>
 </xs:sequence>
 <xs:attribute name="ID" type="xs:integer" use="required" ted:visibility="owner" ted:entityKey="primaryAuto"/>
 <xs:attribute name="Preparation_Identifier" type="xs:token" use="required" ted:entityKey="identifier" ted:helpText="Your shorthand for this preparation"/>
</xs:complexType>

<xs:complexType name="Instrument">
 <xs:annotation>
  <xs:documentation>
   In order to add a new type of instrument, you must do two things:
     1. Define a new complex type to represent the instrument type.
     2. Add that element in the choice group, below.
  </xs:documentation>
 </xs:annotation>
  <xs:sequence>
   <xs:choice ted:label="Instrument Type">
    <xs:element name="Confocal_Microscope" type="CM_Instrument"/>
   </xs:choice>
   <xs:element name="Notes" type="xs:string" minOccurs="0" ted:textRows="4" ted:textColumns="40"/>
 </xs:sequence>
 <xs:attribute name="ID" type="xs:integer" use="required" ted:visibility="owner" ted:entityKey="primaryAuto"/>
 <xs:attribute name="Setup_Identifier" type="xs:token" use="required" ted:entityKey="identifier" ted:helpText="Your shorthand for this setup"/>
</xs:complexType>

<xs:complexType name="Image_Stack">
 <xs:sequence>
  <xs:element name="Path" type="xs:token" ted:visibility="owner" ted:textColumns="40"/>
  <xs:element name="Creator" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
  <xs:element name="SiteRef" minOccurs="0" maxOccurs="unbounded"
 type="EntityRef" ted:label="Site" ted:entityRef="Site"  ted:action="replaceRef"/>
  <xs:element name="Subject" type="xs:token" minOccurs="0" maxOccurs="unbounded" ted:visibility="delivery"/>
  <xs:element name="Caption" type="xs:token" ted:textColumns="40"/>
  <xs:element name="Rights" type="xs:token"/>
  <xs:choice ted:label="Series Type" ted:helpText="Use &quot;Mono&quot; for single TIFFs.">
<!-- This empty element seems a bit odd, but for the end user it will be
 convenient; otherwise one has to tie together, say, a stackType attribute and,
 if the attribute is SERIES then there has to be a Series element. -->
    <xs:element name="Mono">
     <xs:complexType>
     </xs:complexType>
    </xs:element>
    <xs:element name="Series" type="Series"/>
  </xs:choice>
  <xs:element name="PreparationRef" type="EntityRef" ted:label="Preparation" ted:entityRef="Preparation" ted:action="replaceRef"/>
  <xs:element name="InstrumentRef" type="EntityRef" ted:label="Instrument" ted:entityRef="Instrument_Setup" ted:action="replaceRef"/>
  <xs:element name="LUTRef" type="EntityRef" minOccurs="0" ted:label="LUT" ted:entityRef="Lookup_Table" ted:visibility="owner"/>
  <xs:element name="Sampling" type="xs:string" minOccurs="0" ted:textColumns="40"/>
  <xs:element name="Viewing_Note" type="xs:string" minOccurs="0" ted:textRows="4" ted:textColumns="40"/>
  <xs:element name="Artifact" type="xs:string" minOccurs="0" maxOccurs="unbounded" ted:textColumns="40"/>
 </xs:sequence>
  <xs:attribute name="Created_Date" type="xs:date" use="required" ted:helpText="YYYY-MM-DD, eg. &quot;1999-05-02&quot;"/>
  <xs:attribute name="ID" type="xs:token" use="required" ted:visibility="system" ted:helpText="(leave blank)"/>
  <xs:attribute name="URN" type="xs:token" use="required" ted:visibility="system" ted:helpText="(leave blank)" ted:asynch="urn" ted:asynchAction="mets"/>
  <xs:attribute name="Thumbnail_HREF" type="xs:token" use="required" ted:visibility="system" ted:helpText="(leave blank)"/>
  <xs:attribute name="Fullsize_URN" type="xs:token" use="required" ted:visibility="system" ted:helpText="(leave blank)"/>
  <xs:attribute name="Image_Type" use="required">
   <xs:simpleType>
    <xs:restriction base="token">
     <xs:enumeration value="bilevel"/>
     <xs:enumeration value="greyscale"/>
     <xs:enumeration value="palette color"/>
     <xs:enumeration value="full color"/>
    </xs:restriction>
   </xs:simpleType>
  </xs:attribute>
  <xs:attribute name="Planar_Configuration" default="1" ted:helpText="If
  unsure, use &quot;1&quot;">
   <xs:simpleType>
    <xs:restriction base="integer">
     <xs:enumeration value="1"/>
     <xs:enumeration value="2"/>
    </xs:restriction>
   </xs:simpleType>
  </xs:attribute>
</xs:complexType>

<!--
DESIGN NOTE:

I have put off the problem of organizing the images themselves into series. I
believe it is, in the general case, very difficult. Better to just get
descriptive info about how the filenames map into the series. But are filenames
preserved?

I considered making this a "choice" rather than "sequence"; this would require
us to have a "complex_series" type as well, rather than allowing a stack to have
multiple series associated with it. I decided that the latter approach is more
flexible, and it's not clear what is gained by forcing a stack to have a single
series.
-->
<xs:complexType name="Series">
 <xs:sequence>
  <xs:element name="Z_Series" minOccurs="0" maxOccurs="unbounded">
   <xs:complexType>
    <xs:sequence>
     <xs:element name="File_Naming_Convention" type="xs:string" ted:textRows="2" ted:textColumns="30" ted:visibility="owner"/>
    </xs:sequence>
    <xs:attribute name="Z_Step" type="xs:token" use="required"/>
    <xs:attribute name="Number_Of_Steps" type="xs:integer" use="required"/>
   </xs:complexType>
  </xs:element>
  <xs:element name="T_Series" minOccurs="0" maxOccurs="unbounded">
   <xs:complexType>
    <xs:sequence>
     <xs:element name="File_Naming_Convention" type="xs:string" ted:textRows="2" ted:textColumns="30" ted:visibility="owner"/>
    </xs:sequence>
    <xs:attribute name="T_Step" type="xs:token" use="required"/>
    <xs:attribute name="Number_Of_Steps" type="xs:integer" use="required"/>
   </xs:complexType>
  </xs:element>
  <xs:element name="XY_Series" minOccurs="0" maxOccurs="unbounded">
   <xs:complexType>
    <xs:sequence>
     <xs:element name="File_Naming_Convention" type="xs:string" ted:textRows="2" ted:textColumns="30" ted:visibility="owner"/>
    </xs:sequence>
    <xs:attribute name="X_Step" type="xs:token" use="required"/>
    <xs:attribute name="Y_Step" type="xs:token" use="required"/>
    <xs:attribute name="Number_Of_Steps" type="xs:integer" use="required"/>
   </xs:complexType>
  </xs:element>
  <xs:element name="Channel_Series" minOccurs="0" maxOccurs="unbounded">
   <xs:complexType>
    <xs:annotation>
     <xs:documentation>
      The "Channel_List" is a white space delimited list of decimal channel values.
     </xs:documentation>
    </xs:annotation>
    <xs:sequence>
     <xs:element name="File_Naming_Convention" type="xs:string" ted:textRows="2" ted:textColumns="30" ted:visibility="owner"/>
    </xs:sequence>
<!-- TODO: add support for list type    -->
    <xs:attribute name="Channel_List" type="xs:token" use="required" ted:helpText="Comma
    separated list of channels"/>
    <xs:attribute name="Channel_Unit" type="xs:token" use="required"/>
<!-- redundant   <xs:attribute name="Number_Of_Channels" type="xs:integer" use="required"/> -->
   </xs:complexType>
  </xs:element>
 </xs:sequence>
  <xs:attribute name="Thumbnail_TIFF" type="xs:token" use="required"  ted:form="TIFFEnumeration"
  ted:helpText="Specify the TIFF which will be used to create a thumbnail."/>
<!-- <xs:attribute name="File_List" type="NMTOKENS"/> -->
</xs:complexType>

<xs:simpleType name="decimalList">
 <xs:list itemType="decimal"/>
</xs:simpleType>

<xs:complexType name="FM_Preparation">
 <xs:sequence>
  <xs:element name="Fixative" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
  <xs:element name="Embedment" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
  <xs:element name="Mount_Medium" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
  <xs:element name="Sectioning" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
  <xs:element name="Staining" minOccurs="0" maxOccurs="unbounded">
   <xs:complexType>
    <xs:sequence>
     <xs:element name="Antibody" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
     <xs:element name="Antigen" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
     <xs:element name="Fluorescent_Stain" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
     <xs:element name="Counterstain" type="xs:token" minOccurs="0" maxOccurs="unbounded"/>
    </xs:sequence>
   </xs:complexType>
  </xs:element>
 </xs:sequence>
</xs:complexType>

<xs:complexType name="CM_Instrument">
 <xs:sequence>
  <xs:element name="Manufacturer" type="xs:token"/>
  <xs:element name="Model" type="xs:token"/>
  <xs:element name="Number_Of_Channels" type="xs:int"/>
  <xs:element name="Channel_Description" maxOccurs="unbounded">
    <xs:complexType>
      <xs:attribute name="Channel_Number" type="xs:int" use="required"/>
      <xs:attribute name="Optical_Mode" type="xs:token"/>
      <xs:attribute name="Incident_Light" type="xs:token" use="required"/>
      <xs:attribute name="Detected_Light" type="xs:token" use="required"/>
    </xs:complexType>
  </xs:element>
  <xs:element name="Objective_Medium" type="xs:token" minOccurs="0"/>
  <xs:element name="Objective_Magnification" type="xs:token"/>
  <xs:element name="Auxiliary_Magnification" type="xs:token" minOccurs="0"/>
 </xs:sequence>
</xs:complexType>

<!-- is it useful to be more specific, eg., define a pattern for "pages"? Can we
assume that volume/issue are numeric? Is it safe to assume PMID will always be
integer? -->
<!-- For the time being, I am assuming that publications will not be broken out
into entities at all. KISS. I doubt the amount of duplication will be
significant If it is decided they should be, then Usage attribute needs a layer
of indirection, since the same publication could be used differently by
different projects. -->
<xs:complexType name="Publication">
  <xs:attribute name="Author" type="xs:token" use="required"/>
  <xs:attribute name="Title" type="xs:token" use="required"/>
  <xs:attribute name="Journal" type="xs:token" use="required"/>
  <xs:attribute name="Volume" type="xs:token" use="required"/>
  <xs:attribute name="Issue" type="xs:token" use="required"/>
  <xs:attribute name="Pages" type="xs:token" use="required"/>
  <xs:attribute name="Year" type="xs:gYear" use="required" ted:helpText="eg., &quot;2001&quot;"/>
  <xs:attribute name="PMID" type="xs:integer"/>
  <xs:attribute name="Usage" default="original" ted:helpText="Use
  &quot;citing&quot; for publications which cite this BIL project.">
   <xs:annotation>
    <xs:documentation>
     "Original" indicates that data from this project was originally published
     in this publication.
     "Citing" indicates that data from this project, after appearing in BIL, was
     cited in this publication.
    </xs:documentation>
   </xs:annotation>
   <xs:simpleType>
    <xs:restriction base="token">
     <xs:enumeration value="original"/>
     <xs:enumeration value="citing"/>
    </xs:restriction>
   </xs:simpleType>
  </xs:attribute>
</xs:complexType>

<xs:complexType name="Support">
 <xs:sequence>
  <xs:element name="Misc_Note" type="xs:string" minOccurs="0" ted:textRows="4" ted:textColumns="40"/>
 </xs:sequence>
  <xs:attribute name="Title" type="xs:token" use="required"/>
  <xs:attribute name="ID" type="xs:token" use="required"/>
  <xs:attribute name="Funding_Organization" type="xs:token" use="required"/>
</xs:complexType>

<xs:complexType name="Subgroup">
 <xs:sequence>
  <xs:element name="Name" type="xs:token"/>
  <xs:element name="Description" type="xs:string" ted:textRows="6" ted:textColumns="40"/>
  <xs:element name="Path" type="xs:token" ted:visibility="owner" ted:textColumns="40"/>
  <xs:element name="Image_Stack" type="Image_Stack" minOccurs="0" maxOccurs="unbounded"  ted:page="new" ted:form="StructureSection"/>
  <xs:element name="Subgroup" type="Subgroup" minOccurs="0" maxOccurs="unbounded" ted:page="new" ted:form="StructureSection" ted:asynch="div" ted:asynchDivName="Name"/>
 </xs:sequence>
</xs:complexType>

<xs:complexType name="LUT">
 <xs:sequence>
  <xs:element name="Path" type="xs:token" ted:visibility="owner" ted:textColumns="40"/>
  <xs:element name="Usage_Note" type="xs:string" minOccurs="0" ted:textRows="4" ted:textColumns="40"/>
  <xs:element name="Contents" type="xs:string" minOccurs="0" ted:visibility="system">
   <xs:annotation>
    <xs:documentation>
       The contents of the LUT may be included here.
    </xs:documentation>
   </xs:annotation>
   </xs:element>
 </xs:sequence>
 <xs:attribute name="ID" type="xs:integer" use="required" ted:visibility="owner" ted:entityKey="primaryAuto"/>
 <xs:attribute name="LUT_Identifier" type="xs:token" use="required"
  ted:entityKey="identifier" ted:helpText="Your shorthand name for this LUT"/>
</xs:complexType>

<!-- These global element declarations are here so that we can access them
programmatically; if it is felt that they clutter up the schema, we could enable
SOM to generate them on demand from the type defs, or by walking down the tree
until you find one. Note that as global elements, these cannot bear occurrence
constraints; otherwise they should be identical to their counterparts within project.-->

<xs:element name="Subgroup" type="Subgroup" ted:form="StructureSection"/>

<xs:element name="Image_Stack" type="Image_Stack" ted:page="new" ted:form="StructureSection"/>

   <xs:element name="Datasets" ted:page="new" ted:view="swingStructureView" ted:form="StructureSection">
    <xs:complexType>
     <xs:sequence>
      <xs:element name="Subgroup" type="Subgroup" minOccurs="0" maxOccurs="unbounded" ted:form="StructureSection"/>
      <xs:element name="Image_Stack" type="Image_Stack" minOccurs="0"
      maxOccurs="unbounded" ted:page="new" ted:form="StructureSection"/>
      <xs:element name="Path" type="xs:token" ted:visibility="owner" ted:textColumns="40"/>
      <xs:element name="Lookup_Table" type="LUT" minOccurs="0"
      maxOccurs="unbounded" ted:visibility="owner" ted:form="LutSection"/>
     </xs:sequence>
    </xs:complexType>
   </xs:element>

<xs:element name="Lookup_Table" type="LUT" ted:form="LutSection"/>

</xs:schema>


