structureState element to structure view Id is a many to one relationship - so viewId...
[jalview.git] / schemas / vamsas.xsd
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- edited with XMLSpy v2006 sp1 U (http://www.altova.com) by ioh[ (o[ih[oh) -->
3 <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:vamsas="www.vamsas.ac.uk/jalview/version2" targetNamespace="www.vamsas.ac.uk/jalview/version2" elementFormDefault="qualified" attributeFormDefault="unqualified">
4         <xs:complexType name="VAMSAS">
5                 <xs:sequence>
6                         <xs:element name="Tree" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>
7                         <xs:element ref="vamsas:SequenceSet" minOccurs="0" maxOccurs="unbounded"/>
8                 </xs:sequence>
9         </xs:complexType>
10         <xs:complexType name="mapListType">
11                 <xs:annotation>
12                         <xs:documentation> 
13                                 developed after mapRangeType from http://www.vamsas.ac.uk/schemas/1.0/vamsasTypes
14                         </xs:documentation>
15                         <xs:documentation>
16                                 This effectively represents a java.util.MapList object
17                         </xs:documentation>
18                 </xs:annotation>
19                 <xs:sequence>
20                         <xs:element name="mapListFrom" minOccurs="0" maxOccurs="unbounded">
21                                 <xs:annotation>
22                                         <xs:documentation> a region from start to end inclusive</xs:documentation>
23                                 </xs:annotation>
24                                 <xs:complexType>
25                                         <xs:attribute name="start" type="xs:int" use="required"/>
26                                         <xs:attribute name="end" type="xs:int" use="required"/>
27                                 </xs:complexType>
28                         </xs:element>                                   
29                         <xs:element name="mapListTo" minOccurs="0" maxOccurs="unbounded">
30                                 <xs:annotation>
31                                         <xs:documentation> a region from start to end inclusive</xs:documentation>
32                                 </xs:annotation>
33                                 <xs:complexType>
34                                         <xs:attribute name="start" type="xs:int" use="required"/>
35                                         <xs:attribute name="end" type="xs:int" use="required"/>
36                                 </xs:complexType>
37                         </xs:element>                                   
38                 </xs:sequence>
39                 <xs:attribute name="mapFromUnit" type="xs:positiveInteger" use="required">
40                         <xs:annotation>
41                                 <xs:documentation>number of dictionary symbol widths involved in each
42                                         mapped position on this sequence (for example, 3 for a dna sequence exon
43                                         region that is being mapped to a protein sequence). This is optional,
44                                         since the unit can be usually be inferred from the dictionary type of
45                                         each sequence involved in the mapping. </xs:documentation>
46                         </xs:annotation>
47                 </xs:attribute>
48                 <xs:attribute name="mapToUnit" type="xs:positiveInteger" use="required">
49                         <xs:annotation>
50                                 <xs:documentation>number of dictionary symbol widths involved in each
51                                         mapped position on this sequence (for example, 3 for a dna sequence exon
52                                         region that is being mapped to a protein sequence). This is optional,
53                                         since the unit can be usually be inferred from the dictionary type of
54                                         each sequence involved in the mapping. </xs:documentation>
55                         </xs:annotation>
56                 </xs:attribute>
57         </xs:complexType>
58         <xs:element name="Mapping">
59                 <xs:complexType>
60                         <xs:annotation>
61                                 <xs:documentation>
62                                         Represent the jalview.datamodel.Mapping object - it also provides
63                                         a way of storing sequences that are mapped 'to' without adding them
64                                         to the sequence set (which will mean they are then added to the alignment too).
65                                 </xs:documentation>
66                         </xs:annotation>
67                         <xs:complexContent>
68                                 <xs:extension base="vamsas:mapListType">
69                                         <xs:sequence>
70                                                 <xs:choice minOccurs="0" maxOccurs="1">
71                                                         <xs:element ref="vamsas:Sequence"/>
72                                                         <xs:element name="dseqFor">
73                                                                 <xs:simpleType>
74                                                                         <xs:restriction base="xs:string">
75                                                                                 <xs:annotation>
76                                                                                         <xs:documentation>The sequence whose dataset sequence is to be referenced here</xs:documentation>
77                                                                                 </xs:annotation>
78                                                                         </xs:restriction>
79                                                                 </xs:simpleType>
80                                                         </xs:element>
81                                                 </xs:choice>
82                                         </xs:sequence>
83                                 </xs:extension>
84                         </xs:complexContent>    
85                 </xs:complexType>
86         </xs:element>
87         <xs:element name="AlcodonFrame">
88                 <xs:complexType>
89                         <xs:sequence>
90                                 <xs:element name="alcodon" minOccurs="0" maxOccurs="unbounded">
91                                         <xs:complexType>
92                                                 <xs:annotation>
93                                                         <xs:documentation>
94                                                                 specifies a series of aligned codons from an associated DNA sequence alignment that when translated correspond to columns of a peptide alignment.
95                                                                 Element may have either all pos1,2,3 attributes specified, or none at all (indicating a gapped column with no translated peptide).
96                                                         </xs:documentation>
97                                                 </xs:annotation>
98                                                 <xs:attribute name="pos1" type="xs:integer" use="optional"/>
99                                                 <xs:attribute name="pos2" type="xs:integer" use="optional"/>
100                                                 <xs:attribute name="pos3" type="xs:integer" use="optional"/>
101                                         </xs:complexType>
102                                 </xs:element>
103                                 <xs:element name="alcodMap" minOccurs="0" maxOccurs="unbounded">
104                                         <xs:complexType>
105                                                 <xs:sequence>
106                                                         <xs:element ref="vamsas:Mapping" maxOccurs="1" minOccurs="1">
107                                                                 <xs:annotation>
108                                                                         <xs:documentation>
109                                                                                 a Mapping entry and an associated protein sequence
110                                                                         </xs:documentation>
111                                                                 </xs:annotation>
112                                                         </xs:element>
113                                                 </xs:sequence>
114                                                 <xs:attribute name="dnasq" type="xs:string" use="required">
115                                                         <xs:annotation>
116                                                                 <xs:documentation>
117                                                                         internal jalview id for the dnasq for this mapping.
118                                                                 </xs:documentation>
119                                                         </xs:annotation>
120                                                 </xs:attribute>
121                                         </xs:complexType>
122                                         
123                                 </xs:element>
124                                 
125                         </xs:sequence>
126                 </xs:complexType>
127         </xs:element>
128         <xs:element name="Sequence">
129                 <xs:complexType>
130                         <xs:complexContent>
131                                 <xs:extension base="vamsas:SequenceType">
132                                         <xs:sequence>
133                                                 <xs:element name="DBRef" minOccurs="0" maxOccurs="unbounded">
134                                                         <xs:complexType>
135                                                                 <xs:sequence>
136                                                                         <xs:element ref="vamsas:Mapping" minOccurs="0" maxOccurs="1"/>
137                                                                 </xs:sequence>                                                                                                  
138                                                                 <xs:attribute name="source" type="xs:string"/>
139                                                                 <xs:attribute name="version" type="xs:string"/>
140                                                                 <xs:attribute name="accessionId" type="xs:string"/>
141                                                         </xs:complexType>
142                                                 </xs:element>
143                                         </xs:sequence>
144                                         <xs:attribute name="dsseqid" type="xs:string" use="optional">
145                                                 <xs:annotation>
146                                                         <xs:documentation>
147                                                                 dataset sequence id for this sequence. Will be created as union of sequences.
148                                                         </xs:documentation>
149                                                 </xs:annotation>
150                                         </xs:attribute>
151                                 </xs:extension>
152                         </xs:complexContent>
153                 </xs:complexType>
154         </xs:element>
155         <xs:element name="Annotation">
156                 <xs:complexType>
157                         <xs:sequence>
158                                 <xs:element ref="vamsas:annotationElement" minOccurs="0" maxOccurs="unbounded"/>
159                                 <xs:element name="label" type="xs:string"/>
160                                 <xs:element name="description" type="xs:string" minOccurs="0"/>
161                                 <xs:element name="thresholdLine" minOccurs="0">
162                                         <xs:complexType>
163                                                 <xs:attribute name="label" type="xs:string"/>
164                                                 <xs:attribute name="value" type="xs:float"/>
165                                                 <xs:attribute name="colour" type="xs:int"/>
166                                         </xs:complexType>
167                                 </xs:element>
168                         </xs:sequence>
169                         <xs:attribute name="graph" type="xs:boolean" use="required"/>
170                         <xs:attribute name="graphType" type="xs:int" use="optional"/>
171                         <xs:attribute name="sequenceRef" type="xs:string" use="optional"/>
172                         <xs:attribute name="graphColour" type="xs:int" use="optional"/>
173                         <xs:attribute name="graphGroup" type="xs:int" use="optional"/>
174                         <xs:attribute name="id" type="xs:string" use="optional"/>
175                         <xs:attribute name="scoreOnly" type="xs:boolean" use="optional" default="false"/>
176                         <xs:attribute name="score" type="xs:double" use="optional"/>
177                         <xs:attribute name="visible" type="xs:boolean" use="optional"/>
178                 </xs:complexType>
179         </xs:element>   
180         <xs:element name="SequenceSet">
181                 <xs:complexType>
182                         <xs:sequence>
183                                 <xs:element ref="vamsas:Sequence" minOccurs="0" maxOccurs="unbounded"/>
184                                 <xs:element ref="vamsas:Annotation" minOccurs="0" maxOccurs="unbounded"/>
185                                 <xs:element name="sequenceSetProperties" minOccurs="0" maxOccurs="unbounded">
186                                         <xs:complexType>
187                                                 <xs:attribute name="key" type="xs:string"/>
188                                                 <xs:attribute name="value" type="xs:string"/>
189                                         </xs:complexType>
190                                 </xs:element>
191                                 <xs:element ref="vamsas:AlcodonFrame" minOccurs="0" maxOccurs="unbounded"/>
192                         </xs:sequence>
193                         <xs:attribute name="gapChar" type="xs:string" use="required"/>
194                         <xs:attribute name="datasetId" type="xs:string" use="optional">
195                                 <xs:annotation>
196                                         <xs:documentation>
197                                                 reference to set where jalview will gather the dataset sequences for all sequences in the set. 
198                                         </xs:documentation>
199                                 </xs:annotation>
200                         </xs:attribute>
201                 </xs:complexType>
202         </xs:element>
203         <xs:element name="annotationElement">
204                 <xs:complexType>
205                         <xs:sequence>
206                                 <xs:element name="displayCharacter" type="xs:string" minOccurs="0"/>
207                                 <xs:element name="description" type="xs:string" minOccurs="0"/>
208                                 <xs:element name="secondaryStructure" minOccurs="0">
209                                         <xs:simpleType>
210                                                 <xs:restriction base="xs:string">
211                                                         <xs:length value="1"/>
212                                                 </xs:restriction>
213                                         </xs:simpleType>
214                                 </xs:element>
215                                 <xs:element name="value" type="xs:float" minOccurs="0"/>
216                         </xs:sequence>
217                         <xs:attribute name="position" type="xs:int" use="required"/>
218                         <xs:attribute name="colour" type="xs:int" use="optional"/>
219                 </xs:complexType>
220         </xs:element>
221         <xs:complexType name="SequenceType">
222                 <xs:sequence>
223                         <xs:element name="sequence" type="xs:string" minOccurs="0"/>
224                         <xs:element name="name" type="xs:string" minOccurs="0"/>
225                 </xs:sequence>
226                 <xs:attribute name="id" type="xs:string"/>
227                 <xs:attribute name="description" type="xs:string"/>
228         </xs:complexType>
229 </xs:schema>