-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathProgram.xsd
119 lines (102 loc) · 4.66 KB
/
Program.xsd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
<?xml version="1.0" encoding="UTF-8"?>
<!-- WARNING: THIS FILE CONTROLS EVERYTHING. CHANGE AT YOUR OWN PERIL -->
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="Program" type="ProgramType"/>
<xs:complexType name="ProgramType">
<xs:sequence>
<xs:element type="xs:string" name="Name" maxOccurs="1" minOccurs="0"/>
<xs:element type="xs:string" name="MachineName" maxOccurs="1" minOccurs="0"/>
<xs:element type="MetaDataType" name="MetaData" maxOccurs="1" minOccurs="0"/>
<xs:element type="DefinitionsType" name="Definitions" maxOccurs="1" minOccurs="1"/>
<xs:element type="HierarchyType" name="Hierarchy" maxOccurs="1" minOccurs="1"/>
</xs:sequence>
</xs:complexType>
<!--Hierarchy stuff-->
<xs:complexType name="HierarchyType">
<xs:choice>
<xs:element type="FolderType" name="Collection" maxOccurs="1"/>
<xs:element type="FolderType" name="Group" maxOccurs="unbounded"/>
<xs:element type="ProductType" name="Product" maxOccurs="1"/>
</xs:choice>
</xs:complexType>
<xs:complexType name="FolderType">
<xs:choice maxOccurs="unbounded">
<xs:element type="FolderType" name="Collection" maxOccurs="1" minOccurs="0"/>
<xs:element type="FolderType" name="Group" maxOccurs="unbounded" minOccurs="0"/>
<xs:element type="ProductType" name="Product" maxOccurs="unbounded" minOccurs="0"/>
</xs:choice>
<xs:attribute type="xs:string" name="ref" use="required"/>
</xs:complexType>
<xs:complexType name="ProductType">
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute type="xs:string" name="ref" use="required"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<xs:complexType name="MetaType">
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute type="xs:string" name="name" use="required"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
<xs:complexType name="MetaDataType">
<xs:sequence>
<xs:element type="MetaType" name="Meta" maxOccurs="unbounded" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
<!--HEre's where the definitions go-->
<xs:complexType name="DefinitionsType">
<xs:sequence>
<xs:element type="CollectionsDefType" name="Collections" maxOccurs="1" minOccurs="1"/>
<xs:element type="GroupsDefType" name="Groups" maxOccurs="1" minOccurs="1"/>
<xs:element type="ProductsDefType" name="Products" maxOccurs="1" minOccurs="1"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="CollectionsDefType">
<xs:sequence>
<xs:element type="CollectionDefType" name="Collection" maxOccurs="unbounded" minOccurs="1"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="CollectionDefType">
<xs:sequence>
<xs:element type="AllowNamedType" name="Allow" maxOccurs="unbounded" minOccurs="0"/>
<xs:element type="AllowRegExType" name="AllowRegex" maxOccurs="unbounded" minOccurs="0"/>
</xs:sequence>
<xs:attribute type="xs:string" name="id" use="required"/>
<xs:attribute type="xs:string" name="name" use="required"/>
<xs:attribute type="xs:anyURI" name="url" use="optional"/>
</xs:complexType>
<xs:complexType name="AllowNamedType">
<xs:attribute type="xs:string" name="id" use="required"/>
<xs:attribute type="xs:string" name="name" use="required"/>
<xs:attribute type="xs:string" name="aliases" use="optional"/>
<xs:attribute type="xs:string" name="folder" use="optional"/>
</xs:complexType>
<xs:complexType name="AllowRegExType">
<xs:attribute type="xs:string" name="pattern" use="required"/>
</xs:complexType>
<xs:complexType name="GroupsDefType">
<xs:sequence>
<xs:element type="GroupDefType" name="Group" maxOccurs="unbounded" minOccurs="1"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="GroupDefType">
<xs:attribute type="xs:string" name="id" use="required"/>
<xs:attribute type="xs:string" name="name" use="required"/>
<xs:attribute type="xs:string" name="folder" use="required"/>
<xs:attribute type="xs:anyURI" name="url" use="optional"/>
</xs:complexType>
<xs:complexType name="ProductsDefType">
<xs:sequence>
<xs:element type="ProductDefType" name="Product" maxOccurs="unbounded" minOccurs="1"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="ProductDefType">
<xs:attribute type="xs:string" name="id" use="required"/>
<xs:attribute type="xs:string" name="name" use="required"/>
<xs:attribute type="xs:string" name="folder" use="required"/>
<xs:attribute type="xs:anyURI" name="url" use="optional"/>
</xs:complexType>
</xs:schema>