Merge pull request #487 from mayerwin/patch-1
[mono.git] / mcs / tools / mdoc / Resources / monodoc-ecma.xsd
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!--
3 Author: John Luke <john.luke@gmail.com>
4 This is a (not very strict) schema for the monodoc
5 ecma-provider format.
6 TODO:
7 make base type for summary, remarks, returns, etc
8 alias duplicate attributes
9 make stricter in order and occurance
10 add masterdoc support?
11 -->
12 <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
13
14   <!-- define attributes -->
15   <xs:attribute name="argnames" type="xs:string" />
16   <xs:attribute name="cref" type="xs:string" />
17   <xs:attribute name="Deprecated" type="xs:boolean" />
18   <xs:attribute name="FullName" type="xs:string" />
19   <xs:attribute name="FullNameSP" type="xs:string" />
20   <xs:attribute name="id" type="xs:string" />
21   <xs:attribute name="inherited" type="xs:string" />
22   <xs:attribute name="language" type="xs:string" />
23   <xs:attribute name="Language" type="xs:string" />
24   <xs:attribute name="lang" type="xs:string" />
25   <xs:attribute name="langword" type="xs:string" />
26   <xs:attribute name="Library" type="xs:string" />
27   <xs:attribute name="location" type="xs:string" />
28   <xs:attribute name="Maintainer" type="xs:string" />
29   <xs:attribute name="MemberName" type="xs:string" />
30   <xs:attribute name="name" type="xs:string" />
31   <xs:attribute name="Name" type="xs:string" />
32   <xs:attribute name="namespace" type="xs:string" />
33   <xs:attribute name="propertytype" type="xs:string" />
34   <xs:attribute name="qualify" type="xs:boolean" />
35   <xs:attribute name="RefType" type="xs:string" />
36   <xs:attribute name="returntype" type="xs:string" />
37   <xs:attribute name="source" type="xs:string" />
38   <xs:attribute name="src" type="xs:string" />
39   <xs:attribute name="subset" type="xs:string" />
40   <xs:attribute name="Value" type="xs:string" />
41   <xs:attribute name="version" type="xs:string" />
42   <xs:attribute name="tool" type="xs:string" />
43   <xs:attribute name="type" type="xs:string" />
44   <xs:attribute name="Type" type="xs:string" />
45   <xs:attribute name="TypeParamName" type="xs:string" />
46
47   <!-- define simple elements -->
48   <xs:element name="AssemblyName" type="xs:string" />
49   <xs:element name="AssemblyPublicKey" type="xs:string" />
50   <xs:element name="AssemblyVersion" type="xs:string" />
51   <xs:element name="AssemblyCulture" type="xs:string" />
52   <xs:element name="AttributeName" type="xs:string" />
53   <xs:element name="BaseTypeName" type="xs:string" />
54   <xs:element name="Excluded" type="xs:string" />
55   <xs:element name="ExcludedBaseTypeName" type="xs:string" />
56   <xs:element name="ExcludedLibrary" type="xs:string" />
57   <xs:element name="ExcludedLibraryName" type="xs:string" />
58   <xs:element name="ExcludedTypeName" type="xs:string" />
59   <xs:element name="i" type="xs:string" />
60   <xs:element name="InterfaceName" type="xs:string" />
61   <xs:element name="li" type="xs:string" />
62   <xs:element name="MemberOfLibrary" type="xs:string" />
63   <xs:element name="MemberType" type="xs:string" />
64   <xs:element name="MemberValue" type="xs:string" />
65   <xs:element name="onequarter" />
66   <xs:element name="PRE" />
67   <xs:element name="permille" />
68   <xs:element name="pi" />
69   <xs:element name="pre" />
70   <xs:element name="ReturnType" type="xs:string" />
71   <xs:element name="TypeExcluded" type="xs:string" />
72
73   <!-- define complex elements -->
74   <xs:element name="altcompliant">
75     <xs:complexType>
76       <xs:attribute ref="cref" />
77     </xs:complexType>
78   </xs:element>
79
80   <xs:element name="altmember">
81     <xs:complexType>
82       <xs:simpleContent>
83         <xs:extension base="xs:string">
84           <xs:attribute ref="cref" />
85         </xs:extension>
86       </xs:simpleContent>
87     </xs:complexType>
88   </xs:element>
89
90   <xs:element name="AssemblyInfo">
91     <xs:complexType>
92       <xs:sequence>
93         <xs:element ref="AssemblyName" minOccurs="0" />
94         <xs:element ref="AssemblyPublicKey" minOccurs="0" />
95         <xs:element ref="AssemblyVersion" minOccurs="0" maxOccurs="unbounded" />
96         <xs:element ref="AssemblyCulture" minOccurs="0" />
97         <xs:element ref="Attributes" minOccurs="0" />
98       </xs:sequence>
99     </xs:complexType>
100   </xs:element>
101
102   <xs:element name="Attribute">
103     <xs:complexType>
104       <xs:sequence>
105         <xs:element ref="AttributeName" />
106         <xs:element ref="Excluded" minOccurs="0" />
107         <xs:element ref="ExcludedTypeName" minOccurs="0" />
108         <xs:element ref="ExcludedLibraryName" minOccurs="0" />
109       </xs:sequence>
110     </xs:complexType>
111   </xs:element>
112
113   <xs:element name="Attributes">
114     <xs:complexType>
115       <xs:sequence>
116         <xs:element ref="Attribute" minOccurs="0" maxOccurs="unbounded" />
117       </xs:sequence>
118     </xs:complexType>
119   </xs:element>
120
121   <xs:element name="Base">
122     <xs:complexType>
123       <xs:sequence>
124         <xs:element ref="BaseTypeName" minOccurs="0" />
125         <xs:element ref="BaseTypeArguments" minOccurs="0" />
126         <xs:element ref="ExcludedBaseTypeName" minOccurs="0" />
127         <xs:element ref="ExcludedLibraryName" minOccurs="0" />
128       </xs:sequence>
129     </xs:complexType>
130   </xs:element>
131
132   <xs:element name="BaseTypeArgument">
133     <xs:complexType mixed="true">
134       <xs:attribute ref="TypeParamName" />
135     </xs:complexType>
136   </xs:element>
137
138   <xs:element name="BaseTypeArguments">
139     <xs:complexType>
140       <xs:sequence>
141         <xs:element ref="BaseTypeArgument" minOccurs="0" />
142       </xs:sequence>
143     </xs:complexType>
144   </xs:element>
145
146   <xs:element name="block">
147     <xs:complexType mixed="true">
148       <xs:choice minOccurs="0" maxOccurs="unbounded">
149         <xs:element ref="block" />
150         <xs:element ref="c" />
151         <xs:element ref="code" />
152         <xs:element ref="format" />
153         <xs:element ref="list" />
154         <xs:element ref="para" />
155         <xs:element ref="paramref" />
156         <xs:element ref="see" />
157         <xs:element ref="subscript" />
158         <xs:element ref="sup" />
159         <xs:element ref="pi" />
160         <xs:element ref="typeparamref" />
161       </xs:choice>
162       <xs:attribute ref="subset" />
163       <xs:attribute ref="type" />
164     </xs:complexType>
165   </xs:element>
166
167   <xs:element name="c">
168     <xs:complexType mixed="true">
169       <xs:choice minOccurs="0" maxOccurs="unbounded">
170         <xs:element ref="code" />
171         <xs:element ref="para" />
172         <xs:element ref="paramref" />
173         <xs:element ref="see" />
174         <xs:element ref="typeparamref" />
175       </xs:choice>
176     </xs:complexType>
177   </xs:element>
178
179   <xs:element name="class">
180     <xs:complexType>
181       <xs:choice minOccurs="0" maxOccurs="unbounded">
182         <xs:element ref="constructor" />
183         <xs:element ref="property" />
184         <xs:element ref="method" />
185         <xs:element ref="field" />
186         <xs:element ref="operator" />
187         <xs:element ref="event" />
188         <xs:element ref="enum" />
189         <xs:element ref="class" />
190         <xs:element ref="struct" />
191         <xs:element ref="interface" />
192         <xs:element ref="delegate" />
193       </xs:choice>
194       <xs:attribute ref="name" />
195       <xs:attribute ref="namespace" />
196     </xs:complexType>
197   </xs:element>
198
199   <xs:element name="code">
200     <xs:complexType>
201       <xs:simpleContent>
202         <xs:extension base="xs:string">
203           <xs:attribute ref="lang" />
204           <xs:attribute ref="language" />
205           <xs:attribute ref="source" />
206           <xs:attribute ref="src" />
207         </xs:extension>
208       </xs:simpleContent>
209     </xs:complexType>
210   </xs:element>
211
212   <xs:element name="constructor">
213     <xs:complexType>
214           <xs:attribute ref="name" />
215           <xs:attribute ref="argnames" />
216     </xs:complexType>
217   </xs:element>
218
219   <xs:element name="delegate">
220     <xs:complexType>
221       <xs:choice maxOccurs="unbounded">
222         <xs:element ref="constructor" />
223         <xs:element ref="method" />
224         <xs:element ref="property" />
225         <xs:element ref="operator" />
226       </xs:choice>
227       <xs:attribute ref="name" />
228       <xs:attribute ref="namespace" />
229     </xs:complexType>
230   </xs:element>
231
232   <xs:element name="description">
233     <xs:complexType mixed="true">
234       <xs:choice minOccurs="0" maxOccurs="unbounded">
235         <xs:element ref="c" />
236         <xs:element ref="block" />
237         <xs:element ref="geq" />
238         <xs:element ref="leq" />
239         <xs:element ref="paramref" />
240         <xs:element ref="para" />
241         <xs:element ref="permille" />
242         <xs:element ref="plusminus" />
243         <xs:element ref="SPAN" />
244         <xs:element ref="see" />
245         <xs:element ref="sub" />
246         <xs:element ref="typeparamref" />
247       </xs:choice>
248     </xs:complexType>
249   </xs:element>
250
251   <xs:element name="Docs">
252     <xs:complexType>
253       <xs:choice minOccurs="0" maxOccurs="unbounded">
254         <xs:element ref="summary" />
255         <xs:element ref="param" />
256         <xs:element ref="exception" />
257         <xs:element ref="returns" />
258         <xs:element ref="remarks" />
259         <xs:element ref="example" />
260         <xs:element ref="value" />
261         <xs:element ref="permission" />
262         <xs:element ref="PermissionSet" />
263         <xs:element ref="altmember" />
264         <xs:element ref="altcompliant" />
265         <xs:element ref="since" />
266         <xs:element ref="threadsafe" />
267         <xs:element ref="typeparam" />
268         <xs:element ref="filterpriority" />
269         <xs:element ref="related" />
270       </xs:choice>
271     </xs:complexType>
272   </xs:element>
273
274   <xs:simpleType name="relatedType">
275     <xs:restriction base="xs:string">
276       <!-- External code/application samples -->
277       <xs:enumeration value="sample"/>
278       <!-- e.g. ECMA, OPC, OData, ... specs -->
279       <xs:enumeration value="specification"/>
280       <!-- e.g. Apple/Android documentation -->
281       <xs:enumeration value="externalDocumentation" />
282       <!-- e.g. a more in-depth article at docs.xamarin.com -->
283       <xs:enumeration value="article" />
284           <!-- e.g. a small article describing succintly a feature -->
285           <xs:enumeration value="recipe" />
286     </xs:restriction>
287   </xs:simpleType>
288
289   <xs:element name="related">
290     <xs:complexType mixed="true">
291       <xs:attribute name="type" type="relatedType" />
292       <xs:attribute name="href" type="xs:anyURI" />
293     </xs:complexType>
294   </xs:element>
295
296   <xs:element name="enum">
297     <xs:complexType>
298       <xs:choice minOccurs="0" maxOccurs="unbounded">
299         <xs:element ref="field" />
300         <xs:element ref="method" />
301       </xs:choice>
302       <xs:attribute ref="name" />
303       <xs:attribute ref="namespace" />
304     </xs:complexType>
305   </xs:element>
306
307   <xs:element name="event">
308     <xs:complexType>
309           <xs:attribute ref="name" />
310           <xs:attribute ref="inherited" />
311     </xs:complexType>
312   </xs:element>
313
314   <xs:element name="example">
315     <xs:complexType mixed="true">
316       <xs:choice maxOccurs="unbounded">
317         <xs:element ref="format" />
318         <xs:element ref="para" />
319         <xs:element ref="code" />
320         <xs:element ref="codelink" />
321         <xs:element ref="c" />
322         <xs:element ref="list" />
323         <xs:element ref="see" />
324       </xs:choice>
325     </xs:complexType>
326   </xs:element>
327
328   <xs:element name="exception">
329     <xs:complexType mixed="true">
330       <xs:choice minOccurs="0" maxOccurs="unbounded">
331         <xs:element ref="block" />
332         <xs:element ref="format" />
333         <xs:element ref="list" />
334         <xs:element ref="para" />
335         <xs:element ref="paramref" />
336         <xs:element ref="see" />
337         <xs:element ref="SPAN" />
338         <xs:element ref="typeparamref" />
339       </xs:choice>
340       <xs:attribute ref="cref" />
341     </xs:complexType>
342   </xs:element>
343
344   <xs:element name="field">
345     <xs:complexType>
346       <xs:attribute ref="name" />
347       <xs:attribute ref="inherited" />
348     </xs:complexType>
349   </xs:element>
350
351   <xs:element name="format">
352     <xs:complexType>
353       <xs:sequence>
354         <xs:any minOccurs="0" processContents="lax" />
355       </xs:sequence>
356       <xs:attribute ref="type" />
357     </xs:complexType>
358   </xs:element>
359
360   <xs:element name="interface">
361     <xs:complexType>
362       <xs:choice minOccurs="0" maxOccurs="unbounded">
363         <xs:element ref="constructor" />
364         <xs:element ref="property" />
365         <xs:element ref="method" />
366         <xs:element ref="field" />
367         <xs:element ref="event" />
368       </xs:choice>
369       <xs:attribute ref="name" />
370       <xs:attribute ref="namespace" />
371     </xs:complexType>
372   </xs:element>
373
374   <xs:element name="Interface">
375     <xs:complexType>
376       <xs:sequence>
377         <xs:element ref="InterfaceName" />
378         <xs:element ref="Excluded" minOccurs="0" />
379       </xs:sequence>
380     </xs:complexType>
381   </xs:element>
382
383   <xs:element name="Interfaces">
384     <xs:complexType>
385       <xs:sequence>
386         <xs:element ref="Interface" minOccurs="0" maxOccurs="unbounded" />
387       </xs:sequence>
388     </xs:complexType>
389   </xs:element>
390
391   <xs:element name="item">
392     <xs:complexType>
393         <xs:sequence>
394           <xs:element ref="term" minOccurs="1" maxOccurs="1" />
395           <xs:element ref="description" minOccurs="0" maxOccurs="unbounded" />
396         </xs:sequence>
397     </xs:complexType>
398   </xs:element>
399
400   <xs:element name="link">
401     <xs:complexType>
402       <xs:simpleContent>
403         <xs:extension base="xs:string">
404           <xs:attribute ref="location" />
405         </xs:extension>
406       </xs:simpleContent>
407     </xs:complexType>
408   </xs:element>
409
410   <xs:element name="list">
411     <xs:complexType>
412         <xs:sequence>
413           <xs:element ref="listheader" minOccurs="0" maxOccurs="1" />
414           <xs:element ref="item" minOccurs="0" maxOccurs="unbounded" />
415         </xs:sequence>
416         <xs:attribute name="type" type="xs:string" />
417     </xs:complexType>
418   </xs:element>
419
420   <xs:element name="listheader">
421     <xs:complexType>
422       <xs:sequence>
423           <xs:element ref="term" />
424           <xs:element ref="description" maxOccurs="unbounded" />
425       </xs:sequence>
426     </xs:complexType>
427   </xs:element>
428
429   <xs:element name="masterdoc">
430     <xs:complexType>
431        <xs:choice minOccurs="0" maxOccurs="unbounded">
432          <xs:element ref="class" />
433          <xs:element ref="delegate" />
434          <xs:element ref="interface" />
435          <xs:element ref="struct" />
436          <xs:element ref="enum" />
437        </xs:choice>
438        <xs:attribute name="assembly" type="xs:string" />
439     </xs:complexType>
440   </xs:element>
441
442   <xs:element name="MemberSignature">
443     <xs:complexType>
444       <xs:attribute ref="Language" />
445       <xs:attribute ref="Value" />
446     </xs:complexType>
447   </xs:element>
448
449   <xs:element name="Link">
450     <xs:complexType>
451       <xs:attribute ref="Type" use="required" />
452       <xs:attribute name="Member" type="xs:string" use="required" />
453     </xs:complexType>
454   </xs:element>
455
456   <xs:element name="Member">
457     <xs:complexType>
458       <xs:sequence>
459         <xs:element ref="MemberSignature" minOccurs="1" maxOccurs="unbounded" />
460         <xs:element ref="MemberType" maxOccurs="1" />
461         <xs:element ref="AssemblyInfo" minOccurs="0" maxOccurs="1" />
462         <xs:element ref="Attributes" minOccurs="0" maxOccurs="1" />
463         <xs:element ref="ReturnValue" minOccurs="0" maxOccurs="1" />
464         <xs:element ref="TypeParameters" minOccurs="0" maxOccurs="1" />
465         <xs:element ref="Parameters" minOccurs="0" maxOccurs="1" />
466         <xs:element ref="MemberValue" minOccurs="0" maxOccurs="1" />
467         <xs:element ref="Docs" maxOccurs="1" />
468         <xs:element ref="Excluded" minOccurs="0" maxOccurs="1" />
469         <xs:element ref="ExcludedLibrary" minOccurs="0" maxOccurs="unbounded" />
470         <xs:element ref="Link" minOccurs="0" maxOccurs="1" />
471       </xs:sequence>
472       <xs:attribute ref="MemberName" />
473       <xs:attribute ref="Deprecated" />
474     </xs:complexType>
475   </xs:element>
476
477   <xs:element name="Members">
478     <xs:complexType>
479       <xs:sequence>
480         <xs:element ref="Member" minOccurs="0" maxOccurs="unbounded" />
481       </xs:sequence>
482     </xs:complexType>
483   </xs:element>
484
485   <xs:element name="method">
486     <xs:complexType>
487       <xs:attribute ref="name" />
488       <xs:attribute ref="argnames" />
489       <xs:attribute ref="inherited" />
490       <xs:attribute ref="returntype" />
491     </xs:complexType>
492   </xs:element>
493
494   <xs:element name="Namespace">
495     <xs:complexType>
496       <xs:sequence>
497         <xs:element ref="Docs" maxOccurs="1" />
498       </xs:sequence>
499       <xs:attribute ref="Name" />
500       <xs:attribute ref="FullName" />
501       <xs:attribute ref="FullNameSP" />
502       <xs:attribute ref="Maintainer" />
503     </xs:complexType>
504   </xs:element>
505
506   <xs:element name="operator">
507     <xs:complexType>
508       <xs:attribute ref="name" />
509       <xs:attribute ref="argnames" />
510     </xs:complexType>
511   </xs:element>
512
513   <xs:element name="para">
514     <xs:complexType mixed="true">
515       <xs:choice minOccurs="0" maxOccurs="unbounded">
516         <xs:element ref="block" />
517         <xs:element ref="i" />
518         <xs:element ref="format" />
519         <xs:element ref="see" />
520         <xs:element ref="geq" />
521         <xs:element ref="leq" />
522         <xs:element ref="list" />
523         <xs:element ref="link" />
524         <xs:element ref="ul" />
525         <xs:element ref="paramref" />
526         <xs:element ref="c" />
527         <xs:element ref="onequarter" />
528         <xs:element ref="sub" />
529         <xs:element ref="superscript" />
530         <xs:element ref="sup" />
531         <xs:element ref="permille" />
532         <xs:element ref="plusminus" />
533         <xs:element ref="SPAN" />
534         <xs:element ref="pi" />
535         <xs:element ref="theta" />
536         <xs:element ref="typeparamref" />
537         <xs:element ref="whitespace" />
538         <xs:element ref="img" />
539       </xs:choice>
540       <xs:attribute ref="id" />
541       <xs:attribute ref="tool" />
542     </xs:complexType>
543   </xs:element>
544
545   <xs:element name="img">
546         <xs:complexType>
547           <xs:attribute name="href" type="xs:string" use="required" />
548           <xs:attribute name="class" type="xs:string" use="optional" />
549         </xs:complexType>
550   </xs:element>
551
552   <xs:element name="param">
553     <xs:complexType mixed="true">
554       <xs:choice minOccurs="0" maxOccurs="unbounded">
555         <xs:element ref="c" />
556         <xs:element ref="format" />
557         <xs:element ref="see" />
558         <xs:element ref="block" />
559         <xs:element ref="geq" />
560         <xs:element ref="leq" />
561         <xs:element ref="paramref" />
562         <xs:element ref="plusminus" />
563         <xs:element ref="para" />
564         <xs:element ref="SPAN" />
565         <xs:element ref="typeparamref" />
566         <xs:element ref="whitespace" />
567       </xs:choice>
568       <xs:attribute ref="name" use="required" />
569     </xs:complexType>
570   </xs:element>
571
572   <xs:element name="paramref">
573     <xs:complexType>
574       <xs:attribute ref="name" use="required" />
575     </xs:complexType>
576   </xs:element>
577
578   <xs:element name="Parameter">
579     <xs:complexType>
580       <xs:sequence>
581         <xs:element ref="Attributes" minOccurs="0" maxOccurs="1" />
582       </xs:sequence>
583       <xs:attribute ref="Name" />
584       <xs:attribute ref="Type" />
585       <xs:attribute ref="RefType" />
586     </xs:complexType>
587   </xs:element>
588
589   <xs:element name="Parameters">
590     <xs:complexType>
591       <xs:sequence>
592         <xs:element ref="Parameter" minOccurs="0" maxOccurs="unbounded" />
593       </xs:sequence>
594     </xs:complexType>
595   </xs:element>
596
597   <xs:element name="permission">
598     <xs:complexType mixed="true">
599       <xs:choice minOccurs="0" maxOccurs="unbounded">
600         <xs:element ref="block" />
601         <xs:element ref="format" />
602         <xs:element ref="para" />
603         <xs:element ref="paramref" />
604         <xs:element ref="see" />
605         <xs:element ref="typeparamref" />
606       </xs:choice>
607       <xs:attribute ref="cref" />
608     </xs:complexType>
609   </xs:element>
610
611   <xs:element name="property">
612     <xs:complexType>
613       <xs:attribute ref="name" />
614       <xs:attribute ref="inherited" />
615       <xs:attribute ref="propertytype" />
616     </xs:complexType>
617   </xs:element>
618
619   <xs:element name="remarks">
620     <xs:complexType mixed="true">
621       <xs:choice minOccurs="0" maxOccurs="unbounded">
622         <xs:element ref="block" />
623         <xs:element ref="c" />
624         <xs:element ref="code" />
625         <xs:element ref="format" />
626         <xs:element ref="para" />
627         <xs:element ref="paramref" />
628         <xs:element ref="PRE" />
629         <xs:element ref="pre" />
630         <xs:element ref="see" />
631         <xs:element ref="ul" />
632         <xs:element ref="example" />
633         <xs:element ref="list" />
634         <xs:element ref="SPAN" />
635         <xs:element ref="typeparamref" />
636       </xs:choice>
637     </xs:complexType>
638   </xs:element>
639
640   <xs:element name="returns">
641     <xs:complexType mixed="true">
642       <xs:choice minOccurs="0" maxOccurs="unbounded">
643         <xs:element ref="c" />
644         <xs:element ref="format" />
645         <xs:element ref="geq" />
646         <xs:element ref="leq" />
647         <xs:element ref="list" />
648         <xs:element ref="para" />
649         <xs:element ref="paramref" />
650         <xs:element ref="pi" />
651         <xs:element ref="see" />
652         <xs:element ref="theta" />
653         <xs:element ref="typeparamref" />
654         <xs:element ref="ul" />
655         <xs:element ref="whitespace" />
656       </xs:choice>
657     </xs:complexType>
658   </xs:element>
659
660   <xs:element name="ReturnValue">
661     <xs:complexType>
662       <xs:sequence>
663         <xs:element ref="ReturnType" minOccurs="0" maxOccurs="1" />
664         <xs:element ref="Attributes" minOccurs="0" />
665       </xs:sequence>
666     </xs:complexType>
667   </xs:element>
668
669   <xs:element name="see">
670     <xs:complexType>
671       <xs:attribute ref="cref" />
672       <xs:attribute ref="langword"  />
673       <xs:attribute ref="qualify"  />
674     </xs:complexType>
675   </xs:element>
676
677   <xs:element name="since">
678     <xs:complexType>
679       <xs:attribute ref="version" />
680     </xs:complexType>
681   </xs:element>
682
683   <xs:element name="SPAN">
684     <xs:complexType mixed="true">
685       <xs:choice minOccurs="0" maxOccurs="unbounded">
686         <xs:element ref="block" />
687         <xs:element ref="format" />
688         <xs:element ref="para" />
689         <xs:element ref="paramref" />
690         <xs:element ref="see" />
691         <xs:element ref="SPAN" />
692         <xs:element ref="typeparamref" />
693       </xs:choice>
694       <xs:attribute ref="version" />
695     </xs:complexType>
696   </xs:element>
697
698   <xs:element name="struct">
699     <xs:complexType>
700       <xs:choice minOccurs="0" maxOccurs="unbounded">
701         <xs:element ref="constructor" />
702         <xs:element ref="property" />
703         <xs:element ref="method" />
704         <xs:element ref="field" />
705         <xs:element ref="operator" />
706         <xs:element ref="struct" />
707         <xs:element ref="class" />
708       </xs:choice>
709       <xs:attribute ref="name" />
710       <xs:attribute ref="namespace" />
711     </xs:complexType>
712   </xs:element>
713
714   <xs:element name="sub">
715     <xs:complexType mixed="true">
716       <xs:choice minOccurs="0" maxOccurs="unbounded">
717         <xs:element ref="paramref" />
718         <xs:element ref="typeparamref" />
719       </xs:choice>
720     </xs:complexType>
721   </xs:element>
722
723   <xs:element name="subscript">
724     <xs:complexType>
725       <xs:attribute name="term" type="xs:string" use="required" />
726     </xs:complexType>
727   </xs:element>
728
729   <xs:element name="summary">
730     <xs:complexType mixed="true">
731       <xs:choice minOccurs="0" maxOccurs="unbounded">
732         <xs:element ref="block" />
733         <xs:element ref="c" />
734         <xs:element ref="format" />
735         <xs:element ref="para" />
736         <xs:element ref="paramref" />
737         <xs:element ref="see" />
738         <xs:element ref="typeparamref" />
739         <xs:element ref="ul" />
740         <xs:element ref="list" />
741       </xs:choice>
742     </xs:complexType>
743   </xs:element>
744
745   <xs:element name="sup">
746     <xs:complexType mixed="true">
747       <xs:choice minOccurs="0" maxOccurs="unbounded">
748         <xs:element ref="i" />
749         <xs:element ref="paramref" />
750         <xs:element ref="typeparamref" />
751       </xs:choice>
752     </xs:complexType>
753   </xs:element>
754
755   <xs:element name="superscript">
756     <xs:complexType>
757       <xs:attribute name="term" type="xs:string" use="required" />
758     </xs:complexType>
759   </xs:element>
760
761   <xs:element name="term">
762     <xs:complexType mixed="true">
763         <xs:choice minOccurs="0" maxOccurs="unbounded">
764           <xs:element ref="block" />
765           <xs:element ref="c" />
766           <xs:element ref="format" />
767           <xs:element ref="geq" />
768           <xs:element ref="leq" />
769           <xs:element ref="see" />
770           <xs:element ref="para"  />
771           <xs:element ref="paramref" />
772           <xs:element ref="pi" />
773           <xs:element ref="plusminus" />
774           <xs:element ref="sup" />
775           <xs:element ref="theta" />
776           <xs:element ref="typeparamref" />
777           <xs:element ref="whitespace" />
778         </xs:choice>
779     </xs:complexType>
780   </xs:element>
781
782   <xs:element name="theta" />
783
784   <xs:element name="threadsafe">
785     <xs:complexType>
786      <xs:sequence>
787        <xs:element ref="para" minOccurs="1" maxOccurs="unbounded" />
788      </xs:sequence>
789     </xs:complexType>
790   </xs:element>
791
792   <xs:element name="ThreadingSafetyStatement">
793     <xs:complexType mixed="true">
794      <xs:sequence>
795        <xs:element ref="link" minOccurs="0" />
796      </xs:sequence>
797     </xs:complexType>
798   </xs:element>
799
800   <xs:element name="ThreadSafetyStatement">
801     <xs:complexType mixed="true">
802      <xs:sequence>
803        <xs:element ref="link" minOccurs="0" />
804      </xs:sequence>
805     </xs:complexType>
806   </xs:element>
807
808   <xs:element name="Type">
809     <xs:complexType>
810       <xs:choice maxOccurs="unbounded">
811         <xs:element ref="TypeSignature" minOccurs="1" />
812         <xs:element ref="MemberOfLibrary" minOccurs="0" />
813         <xs:element ref="AssemblyInfo" minOccurs="1" />
814         <xs:element ref="TypeParameters" minOccurs="0" maxOccurs="1" />
815         <xs:element ref="ThreadingSafetyStatement" minOccurs="0" />
816         <xs:element ref="ThreadSafetyStatement" minOccurs="0" />
817         <xs:element ref="Docs" minOccurs="1" />
818         <xs:element ref="Base" minOccurs="1" />
819         <xs:element ref="Interfaces" minOccurs="1" />
820         <xs:element ref="Attributes" minOccurs="1" />
821         <xs:element ref="Members" minOccurs="1" />
822         <xs:element ref="Parameters" minOccurs="0" />
823         <xs:element ref="ReturnValue" minOccurs="0" />
824         <xs:element ref="TypeExcluded" minOccurs="0" />
825       </xs:choice>
826       <xs:attribute ref="Name" use="required" />
827       <xs:attribute ref="FullName" use="required" />
828       <xs:attribute ref="FullNameSP" />
829       <xs:attribute ref="Maintainer" />
830     </xs:complexType>
831   </xs:element>
832
833   <xs:element name="Types">
834     <xs:complexType>
835       <xs:choice minOccurs="1" maxOccurs="unbounded">
836         <xs:element ref="Type" />
837       </xs:choice>
838       <xs:attribute ref="Library" use="required" />
839     </xs:complexType>
840   </xs:element>
841
842   <xs:element name="typeparam">
843     <xs:complexType mixed="true">
844       <xs:choice minOccurs="0" maxOccurs="unbounded">
845         <xs:element ref="block" />
846         <xs:element ref="c" />
847         <xs:element ref="format" />
848         <xs:element ref="para" />
849         <xs:element ref="paramref" />
850         <xs:element ref="see" />
851         <xs:element ref="typeparamref" />
852       </xs:choice>
853       <xs:attribute ref="name" use="required" />
854     </xs:complexType>
855   </xs:element>
856
857   <xs:element name="typeparamref">
858     <xs:complexType>
859       <xs:attribute ref="name" use="required" />
860     </xs:complexType>
861   </xs:element>
862
863   <xs:element name="TypeParameters">
864     <xs:complexType>
865       <xs:choice maxOccurs="unbounded">
866         <xs:element ref="TypeParameter" />
867       </xs:choice>
868     </xs:complexType>
869   </xs:element>
870
871   <xs:element name="TypeParameter">
872     <xs:complexType mixed="true">
873       <xs:choice minOccurs="0" maxOccurs="unbounded">
874         <xs:element ref="Attributes" />
875         <xs:element ref="Constraints" />
876       </xs:choice>
877       <xs:attribute ref="Name" use="required" />
878     </xs:complexType>
879   </xs:element>
880
881   <xs:element name="Constraints">
882     <xs:complexType mixed="true">
883       <xs:choice minOccurs="0" maxOccurs="unbounded">
884         <xs:element name="ParameterAttribute" type="xs:string" />
885         <xs:element ref="BaseTypeName" />
886         <xs:element ref="InterfaceName" />
887       </xs:choice>
888     </xs:complexType>
889   </xs:element>
890
891   <xs:element name="TypeSignature">
892     <xs:complexType>
893       <xs:attribute ref="Language" use="required" />
894       <xs:attribute ref="Value" use="required" />
895       <xs:attribute ref="Maintainer" />
896     </xs:complexType>
897   </xs:element>
898
899   <xs:element name="ul">
900     <xs:complexType>
901       <xs:sequence>
902         <xs:element ref="li" minOccurs="1" maxOccurs="unbounded" />
903       </xs:sequence>
904     </xs:complexType>
905   </xs:element>
906
907   <xs:element name="value">
908     <xs:complexType mixed="true">
909       <xs:choice minOccurs="0" maxOccurs="unbounded">
910         <xs:element ref="block" />
911         <xs:element ref="c" />
912         <xs:element ref="para" />
913         <xs:element ref="paramref" />
914         <xs:element ref="see" />
915         <xs:element ref="typeparamref" />
916         <xs:element ref="ul" />
917         <xs:element ref="example" />
918         <xs:element ref="list" />
919       </xs:choice>
920     </xs:complexType>
921   </xs:element>
922
923   <!-- 
924     index.xml & namespace-name.xml support 
925     -->
926
927   <!-- define attributes -->
928   <xs:attribute name="Version" type="xs:string" />
929   <xs:attribute name="DisplayName" type="xs:string" />
930   <xs:attribute name="Kind" type="xs:string" />
931
932   <!-- define simple elements -->
933   <xs:element name="Title" type="xs:string" />
934
935   <!-- define complex elements -->
936   <xs:element name="Assemblies">
937     <xs:complexType>
938       <xs:choice minOccurs="0" maxOccurs="unbounded">
939         <xs:element ref="Assembly" />
940       </xs:choice>
941     </xs:complexType>
942   </xs:element>
943
944   <xs:element name="Assembly">
945     <xs:complexType>
946       <xs:choice minOccurs="0" maxOccurs="unbounded">
947         <xs:element ref="AssemblyPublicKey" />
948         <xs:element ref="AssemblyCulture" />
949         <xs:element ref="Attributes" />
950       </xs:choice>
951       <xs:attribute ref="Name" />
952       <xs:attribute ref="Version" />
953     </xs:complexType>
954   </xs:element>
955
956   <xs:element name="Copyright">
957     <xs:complexType mixed="true">
958       <xs:choice minOccurs="0" maxOccurs="unbounded">
959         <xs:element ref="block" />
960         <xs:element ref="code" />
961         <xs:element ref="example" />
962         <xs:element ref="list" />
963         <xs:element ref="para" />
964         <xs:element ref="paramref" />
965         <xs:element ref="see" />
966         <xs:element ref="typeparamref" />
967         <xs:element ref="ul" />
968       </xs:choice>
969     </xs:complexType>
970   </xs:element>
971
972   <xs:element name="ExtensionMethods">
973     <xs:complexType>
974       <xs:sequence>
975         <xs:element ref="ExtensionMethod" minOccurs="0" maxOccurs="unbounded" />
976       </xs:sequence>
977     </xs:complexType>
978   </xs:element>
979
980   <xs:element name="ExtensionMethod">
981     <xs:complexType>
982       <xs:sequence>
983         <xs:element name="Targets" minOccurs="1" maxOccurs="1">
984           <xs:complexType>
985             <xs:choice minOccurs="1" maxOccurs="unbounded">
986               <xs:element name="Target">
987                 <xs:complexType>
988                   <xs:attribute ref="Type" use="required" />
989                 </xs:complexType>
990               </xs:element>
991             </xs:choice>
992           </xs:complexType>
993         </xs:element>
994         <xs:element ref="Member" minOccurs="1" maxOccurs="1" />
995       </xs:sequence>
996     </xs:complexType>
997   </xs:element>
998
999   <xs:element name="Overview">
1000     <xs:complexType>
1001       <xs:choice minOccurs="0" maxOccurs="unbounded">
1002         <xs:element ref="Assemblies" />
1003         <xs:element ref="Copyright" />
1004         <xs:element ref="Remarks" />
1005         <xs:element ref="Title" />
1006         <xs:element name="Types">
1007           <xs:complexType>
1008             <xs:choice minOccurs="0" maxOccurs="unbounded">
1009               <xs:element name="Namespace">
1010                 <xs:complexType>
1011                   <xs:choice minOccurs="0" maxOccurs="unbounded">
1012                     <xs:element name="Type">
1013                       <xs:complexType>
1014                         <xs:attribute ref="Name" use="required" />
1015                         <xs:attribute ref="DisplayName" />
1016                         <xs:attribute ref="Kind" />
1017                       </xs:complexType>
1018                     </xs:element>
1019                   </xs:choice>
1020                   <xs:attribute ref="Name" />
1021                 </xs:complexType>
1022               </xs:element>
1023             </xs:choice>
1024           </xs:complexType>
1025         </xs:element>
1026         <xs:element ref="ExtensionMethods" />
1027       </xs:choice>
1028     </xs:complexType>
1029   </xs:element>
1030
1031   <xs:element name="Remarks">
1032     <xs:complexType mixed="true">
1033       <xs:choice minOccurs="0" maxOccurs="unbounded">
1034         <xs:element ref="block" />
1035         <xs:element ref="code" />
1036         <xs:element ref="example" />
1037         <xs:element ref="list" />
1038         <xs:element ref="para" />
1039         <xs:element ref="paramref" />
1040         <xs:element ref="typeparamref" />
1041         <xs:element ref="see" />
1042         <xs:element ref="ul" />
1043       </xs:choice>
1044     </xs:complexType>
1045   </xs:element>
1046
1047   <!--
1048     ECMA 335 CLILibraryTypes.xml support
1049     -->
1050
1051   <xs:element name="Libraries">
1052     <xs:complexType>
1053       <xs:choice minOccurs="0" maxOccurs="unbounded">
1054         <xs:element ref="Types" minOccurs = "1" maxOccurs="unbounded" />
1055       </xs:choice>
1056     </xs:complexType>
1057   </xs:element>
1058
1059         <xs:element name="codelink">
1060     <xs:complexType>
1061       <xs:attribute name="SampleID" type="xs:string" />
1062       <xs:attribute name="SnippedID" type="xs:string" />
1063     </xs:complexType>
1064         </xs:element>
1065
1066   <xs:element name="filterpriority" type="xs:string" />
1067
1068   <xs:element name="geq" />
1069   <xs:element name="leq" />
1070   <xs:element name="plusminus" />
1071   <xs:element name="whitespace" />
1072
1073   <xs:element name="PermissionSet">
1074     <xs:complexType>
1075       <xs:choice minOccurs="0" maxOccurs="unbounded">
1076         <xs:element name="IPermission">
1077           <xs:complexType>
1078             <xs:attribute name="class" type="xs:string" />
1079             <xs:attribute name="Flags" type="xs:string" />
1080             <xs:attribute name="Name" type="xs:string" />
1081             <xs:attribute name="PathDiscovery" type="xs:string" />
1082             <xs:attribute name="PublicKeyBlob" type="xs:string" />
1083             <xs:attribute name="Read" type="xs:string" />
1084             <xs:attribute name="Unrestricted" type="xs:string" />
1085             <xs:attribute name="version" type="xs:string" />
1086             <xs:attribute name="Window" type="xs:string" />
1087           </xs:complexType>
1088         </xs:element>
1089       </xs:choice>
1090     </xs:complexType>
1091   </xs:element>
1092
1093   <!--
1094     ECMA 334 Annex E Documentation Comments support.
1095     -->
1096
1097   <xs:element name="seealso">
1098     <xs:complexType>
1099       <xs:simpleContent>
1100         <xs:extension base="xs:string">
1101           <xs:attribute ref="cref" />
1102         </xs:extension>
1103       </xs:simpleContent>
1104     </xs:complexType>
1105   </xs:element>
1106
1107   <xs:element name="doc">
1108     <xs:complexType>
1109       <xs:sequence>
1110         <xs:element name="assembly">
1111           <xs:complexType>
1112             <xs:choice>
1113               <xs:element name="name" type="xs:string" />
1114             </xs:choice>
1115           </xs:complexType>
1116         </xs:element>
1117         <xs:element name="members">
1118           <xs:complexType>
1119             <xs:choice minOccurs="0" maxOccurs="unbounded">
1120               <xs:element name="member">
1121                 <xs:complexType>
1122                   <xs:choice minOccurs="0" maxOccurs="unbounded">
1123                     <xs:element ref="seealso" />
1124                     <xs:element ref="example" />
1125                     <xs:element ref="exception" />
1126                     <xs:element ref="param" />
1127                     <xs:element ref="permission" />
1128                     <xs:element ref="PermissionSet" />
1129                     <xs:element ref="remarks" />
1130                     <xs:element ref="returns" />
1131                     <xs:element ref="summary" />
1132                     <xs:element ref="threadsafe" />
1133                     <xs:element ref="typeparam" />
1134                     <xs:element ref="value" />
1135                   </xs:choice>
1136                   <xs:attribute name="name" type="xs:string" />
1137                 </xs:complexType>
1138               </xs:element>
1139             </xs:choice>
1140           </xs:complexType>
1141         </xs:element>
1142       </xs:sequence>
1143     </xs:complexType>
1144   </xs:element>
1145 </xs:schema>
1146