1 | <?xml version="1.0" encoding="UTF-8"?> |
---|
2 | <!-- |
---|
3 | $Revision: 2515 $ |
---|
4 | $Date: 2010-06-24 11:36:11 +0200 (Thu, 24 Jun 2010) $ |
---|
5 | --> |
---|
6 | |
---|
7 | <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"> |
---|
8 | <xs:import namespace="http://www.w3.org/XML/1998/namespace" |
---|
9 | schemaLocation="http://www.w3.org/2005/08/xml.xsd"/> |
---|
10 | |
---|
11 | <!-- root element --> |
---|
12 | <xs:element name="CMD_ComponentSpec"> |
---|
13 | <xs:complexType> |
---|
14 | <xs:sequence> |
---|
15 | <xs:element name="Header"> |
---|
16 | <xs:complexType> |
---|
17 | <xs:sequence> |
---|
18 | <xs:element name="ID" type="xs:anyURI" minOccurs="0"/> |
---|
19 | <xs:element name="Name" type="xs:string" minOccurs="0"/> |
---|
20 | <xs:element name="Description" type="xs:string" minOccurs="0"/> |
---|
21 | </xs:sequence> |
---|
22 | </xs:complexType> |
---|
23 | </xs:element> |
---|
24 | <xs:element name="CMD_Component" type="CMD_Component_type" maxOccurs="unbounded"> |
---|
25 | <xs:annotation> |
---|
26 | <xs:documentation>At the root level there should always be a |
---|
27 | Component.</xs:documentation> |
---|
28 | </xs:annotation> |
---|
29 | </xs:element> |
---|
30 | </xs:sequence> |
---|
31 | <xs:attribute name="isProfile" type="xs:boolean" use="required"/> |
---|
32 | </xs:complexType> |
---|
33 | </xs:element> |
---|
34 | |
---|
35 | <!-- recursive construction: A component can contain elements and/or other components --> |
---|
36 | <xs:group name="group"> |
---|
37 | <xs:sequence> |
---|
38 | <!-- from small (attribute) to big (component) --> |
---|
39 | <xs:element name="AttributeList" type="AttributeList_type" minOccurs="0" maxOccurs="1"/> |
---|
40 | <xs:element name="CMD_Element" type="CMD_Element_type" minOccurs="0" |
---|
41 | maxOccurs="unbounded"> </xs:element> |
---|
42 | <xs:element name="CMD_Component" type="CMD_Component_type" minOccurs="0" |
---|
43 | maxOccurs="unbounded"/> |
---|
44 | </xs:sequence> |
---|
45 | </xs:group> |
---|
46 | |
---|
47 | <!-- type definitions --> |
---|
48 | <xs:complexType name="CMD_Element_type"> |
---|
49 | <xs:sequence> |
---|
50 | <xs:element name="AttributeList" type="AttributeList_type" minOccurs="0" maxOccurs="1"> |
---|
51 | <xs:annotation> |
---|
52 | <xs:documentation>The AttributeList child of an element contains a set of XML |
---|
53 | attributes for that element.</xs:documentation> |
---|
54 | </xs:annotation> |
---|
55 | </xs:element> |
---|
56 | <xs:element minOccurs="0" maxOccurs="1" name="ValueScheme" type="ValueScheme_type"> |
---|
57 | <xs:annotation> |
---|
58 | <xs:documentation>When an element is linked to a regular expression or a |
---|
59 | controlled vocabulary, the ValueScheme sub-element contains more information |
---|
60 | about this.</xs:documentation> |
---|
61 | </xs:annotation> |
---|
62 | </xs:element> |
---|
63 | </xs:sequence> |
---|
64 | <xs:attributeGroup ref="clarin_element_attributes"/> |
---|
65 | </xs:complexType> |
---|
66 | |
---|
67 | |
---|
68 | <xs:complexType name="ValueScheme_type"> |
---|
69 | <xs:choice> |
---|
70 | <xs:element name="pattern" type="xs:string" maxOccurs="1"> |
---|
71 | <xs:annotation> |
---|
72 | <xs:documentation>Specification of a regular expression the element should |
---|
73 | comply with.</xs:documentation> |
---|
74 | </xs:annotation> |
---|
75 | </xs:element> |
---|
76 | <xs:element name="enumeration" type="enumeration_type"> |
---|
77 | <xs:annotation> |
---|
78 | <xs:documentation>A list of the allowed values of a controlled |
---|
79 | vocabulary.</xs:documentation> |
---|
80 | </xs:annotation> |
---|
81 | </xs:element> |
---|
82 | </xs:choice> |
---|
83 | </xs:complexType> |
---|
84 | |
---|
85 | |
---|
86 | <xs:complexType name="AttributeList_type"> |
---|
87 | <xs:sequence> |
---|
88 | <xs:element name="Attribute" minOccurs="1" maxOccurs="unbounded"> |
---|
89 | <xs:complexType> |
---|
90 | <xs:sequence> |
---|
91 | <xs:element name="Name" type="xs:string"> |
---|
92 | <xs:annotation> |
---|
93 | <xs:documentation>The name of the attribute.</xs:documentation> |
---|
94 | </xs:annotation> |
---|
95 | </xs:element> |
---|
96 | <xs:element name="ConceptLink" type="xs:anyURI" minOccurs="0"> |
---|
97 | <xs:annotation> |
---|
98 | <xs:documentation>A link to the ISOcat data category registry (or any other concept registry).</xs:documentation> |
---|
99 | </xs:annotation> |
---|
100 | </xs:element> |
---|
101 | <xs:choice> |
---|
102 | <xs:element name="Type" type="allowed_attributetypes_type"> |
---|
103 | <xs:annotation> |
---|
104 | <xs:documentation>For the use of simple XML types as the type of |
---|
105 | the attribute.</xs:documentation> |
---|
106 | </xs:annotation> |
---|
107 | </xs:element> |
---|
108 | <xs:element name="ValueScheme" type="ValueScheme_type"> |
---|
109 | <xs:annotation> |
---|
110 | <xs:documentation>For the use of a regular expression or a |
---|
111 | controlled vocabulary as the type of the |
---|
112 | attribute.</xs:documentation> |
---|
113 | </xs:annotation> |
---|
114 | </xs:element> |
---|
115 | </xs:choice> |
---|
116 | </xs:sequence> |
---|
117 | </xs:complexType> |
---|
118 | </xs:element> |
---|
119 | </xs:sequence> |
---|
120 | </xs:complexType> |
---|
121 | |
---|
122 | <xs:complexType name="CMD_Component_type"> |
---|
123 | <xs:group ref="group" minOccurs="0"/> |
---|
124 | <xs:attributeGroup ref="clarin_component_attributes"/> |
---|
125 | </xs:complexType> |
---|
126 | |
---|
127 | |
---|
128 | <!-- list of all attributes that can be bound to a cl_el --> |
---|
129 | <xs:attributeGroup name="clarin_element_attributes"> |
---|
130 | <xs:attribute name="name" type="xs:Name" use="required"> |
---|
131 | <xs:annotation> |
---|
132 | <xs:documentation>The name of the element.</xs:documentation> |
---|
133 | </xs:annotation> |
---|
134 | </xs:attribute> |
---|
135 | <xs:attribute name="ConceptLink" type="xs:anyURI"> |
---|
136 | <xs:annotation> |
---|
137 | <xs:documentation>A link to the ISOcat data category registry (or any other concept |
---|
138 | registry).</xs:documentation> |
---|
139 | </xs:annotation> |
---|
140 | </xs:attribute> |
---|
141 | <xs:attribute name="ValueScheme" type="allowed_attributetypes_type"> |
---|
142 | <xs:annotation> |
---|
143 | <xs:documentation>Used to specify that an element has a simple XML type (string, |
---|
144 | integer, etc)</xs:documentation> |
---|
145 | </xs:annotation> |
---|
146 | </xs:attribute> |
---|
147 | <xs:attribute name="CardinalityMin" type="cardinality_type"> |
---|
148 | <xs:annotation> |
---|
149 | <xs:documentation>Minimal number of occurrences.</xs:documentation> |
---|
150 | </xs:annotation> |
---|
151 | </xs:attribute> |
---|
152 | <xs:attribute name="CardinalityMax" type="cardinality_type"> |
---|
153 | <xs:annotation> |
---|
154 | <xs:documentation>Maximal number of occurrences.</xs:documentation> |
---|
155 | </xs:annotation> |
---|
156 | </xs:attribute> |
---|
157 | <xs:attribute name="Documentation" type="xs:string"> |
---|
158 | <xs:annotation> |
---|
159 | <xs:documentation>Some information an application (eg Arbil) can display to give |
---|
160 | guidance to the user when entering metadata.</xs:documentation> |
---|
161 | </xs:annotation> |
---|
162 | </xs:attribute> |
---|
163 | <xs:attribute name="DisplayPriority" type="xs:integer"> |
---|
164 | <xs:annotation> |
---|
165 | <xs:documentation>The element with the highest priority will be displayed as the |
---|
166 | label for a metadata file (eg in Arbil)</xs:documentation> |
---|
167 | </xs:annotation> |
---|
168 | </xs:attribute> |
---|
169 | <xs:attribute name="Multilingual" type="xs:boolean"> |
---|
170 | <xs:annotation> |
---|
171 | <xs:documentation>Indicates that this element can have values in multiple languages |
---|
172 | (and thus is repeatable). This will result in the possibility of using the |
---|
173 | xml:lang attribute in the metadata instances that are |
---|
174 | created.</xs:documentation> |
---|
175 | </xs:annotation> |
---|
176 | </xs:attribute> |
---|
177 | </xs:attributeGroup> |
---|
178 | |
---|
179 | <!-- list of all attributes that can be bound to a cl_comp --> |
---|
180 | <xs:attributeGroup name="clarin_component_attributes"> |
---|
181 | <xs:attribute name="name" type="xs:Name"/> |
---|
182 | <xs:attribute name="ComponentId" type="xs:anyURI"> |
---|
183 | <xs:annotation> |
---|
184 | <xs:documentation>Indicates that a component (using its unique ComponentId issued by |
---|
185 | the ComponentRegistry) should be included.</xs:documentation> |
---|
186 | </xs:annotation> |
---|
187 | </xs:attribute> |
---|
188 | <xs:attribute name="ConceptLink" type="xs:anyURI"> |
---|
189 | <xs:annotation> |
---|
190 | <xs:documentation>A link to the ISOcat data category registry (or any other concept |
---|
191 | registry). Currently not used.</xs:documentation> |
---|
192 | </xs:annotation> |
---|
193 | </xs:attribute> |
---|
194 | <xs:attribute name="filename" type="xs:anyURI"> |
---|
195 | <xs:annotation> |
---|
196 | <xs:documentation>Outdated way of including an external component. Here for backward |
---|
197 | compatibility with the XML-cmdi-toolkit.</xs:documentation> |
---|
198 | </xs:annotation> |
---|
199 | </xs:attribute> |
---|
200 | |
---|
201 | <!-- (components cannot have a ValueScheme attribute) --> |
---|
202 | |
---|
203 | <xs:attribute name="CardinalityMin" type="cardinality_type"/> |
---|
204 | <xs:attribute name="CardinalityMax" type="cardinality_type"/> |
---|
205 | <xs:attribute ref="xml:base"/> |
---|
206 | </xs:attributeGroup> |
---|
207 | |
---|
208 | |
---|
209 | <xs:simpleType name="cardinality_type"> |
---|
210 | <xs:annotation> |
---|
211 | <xs:documentation>cardinality for elements and components</xs:documentation> |
---|
212 | </xs:annotation> |
---|
213 | <xs:union> |
---|
214 | <xs:simpleType> |
---|
215 | <xs:list itemType="xs:nonNegativeInteger"/> |
---|
216 | </xs:simpleType> |
---|
217 | <xs:simpleType> |
---|
218 | <xs:restriction base="xs:string"> |
---|
219 | <xs:enumeration value="unbounded"/> |
---|
220 | </xs:restriction> |
---|
221 | </xs:simpleType> |
---|
222 | </xs:union> |
---|
223 | </xs:simpleType> |
---|
224 | |
---|
225 | <xs:simpleType name="allowed_attributetypes_type"> |
---|
226 | <xs:annotation> |
---|
227 | <xs:documentation>Subset of XSD types that are allowed as CMD type</xs:documentation> |
---|
228 | </xs:annotation> |
---|
229 | |
---|
230 | <xs:restriction base="xs:token"> |
---|
231 | <xs:enumeration value="boolean"/> |
---|
232 | <xs:enumeration value="decimal"/> |
---|
233 | <xs:enumeration value="float"/> |
---|
234 | <xs:enumeration value="string"/> |
---|
235 | <xs:enumeration value="anyURI"/> |
---|
236 | <xs:enumeration value="date"/> |
---|
237 | <xs:enumeration value="gDay"/> |
---|
238 | <xs:enumeration value="gMonth"/> |
---|
239 | <xs:enumeration value="gYear"/> |
---|
240 | <xs:enumeration value="time"/> |
---|
241 | <xs:enumeration value="dateTime"/> |
---|
242 | </xs:restriction> |
---|
243 | </xs:simpleType> |
---|
244 | |
---|
245 | <xs:complexType name="enumeration_type"> |
---|
246 | <xs:annotation> |
---|
247 | <xs:documentation>controlled vocabularies</xs:documentation> |
---|
248 | </xs:annotation> |
---|
249 | <xs:choice minOccurs="0" maxOccurs="unbounded"> |
---|
250 | <xs:element name="item" type="item_type"> |
---|
251 | <xs:annotation> |
---|
252 | <xs:documentation>An item from a controlled vocabulary.</xs:documentation> |
---|
253 | </xs:annotation> |
---|
254 | </xs:element> |
---|
255 | <xs:element name="appinfo" type="xs:string"> |
---|
256 | <xs:annotation> |
---|
257 | <xs:documentation>End-user guidance about the value of the controlled vocabulary |
---|
258 | as a whole. Currently not used.</xs:documentation> |
---|
259 | </xs:annotation> |
---|
260 | </xs:element> |
---|
261 | </xs:choice> |
---|
262 | </xs:complexType> |
---|
263 | |
---|
264 | <xs:complexType name="item_type"> |
---|
265 | <xs:simpleContent> |
---|
266 | <xs:extension base="xs:string"> |
---|
267 | <xs:attribute type="xs:anyURI" name="ConceptLink"> |
---|
268 | <xs:annotation> |
---|
269 | <xs:documentation>A link to the ISOcat data category registry (or any other |
---|
270 | concept registry) related to this controllec vocabulary |
---|
271 | item.</xs:documentation> |
---|
272 | </xs:annotation> |
---|
273 | </xs:attribute> |
---|
274 | <xs:attribute type="xs:string" name="AppInfo"> |
---|
275 | <xs:annotation> |
---|
276 | <xs:documentation>End-user guidance about the value of this controlled |
---|
277 | vocabulary item.</xs:documentation> |
---|
278 | </xs:annotation> |
---|
279 | </xs:attribute> |
---|
280 | </xs:extension> |
---|
281 | </xs:simpleContent> |
---|
282 | </xs:complexType> |
---|
283 | |
---|
284 | </xs:schema> |
---|