-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathBlazonML.xsd
451 lines (451 loc) · 15.9 KB
/
BlazonML.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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://drawshield.net/blazonML"
targetNamespace="http://drawshield.net/blazonML" xmlns:blazon="http://drawshield.net/blazonML"
vc:maxVersion="1.1" vc:minVersion="1.0" xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning">
<xs:element name="blazon">
<xs:complexType>
<xs:sequence>
<xs:element name="input">
<xs:complexType>
<xs:sequence maxOccurs="unbounded">
<xs:element name="token" type="xs:string"/>
</xs:sequence>
<xs:attribute name="blazonText"/>
</xs:complexType>
</xs:element>
<xs:element ref="shield"/>
<xs:element minOccurs="0" name="achievement">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="crest">
<xs:annotation>
<xs:documentation/>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:element ref="location"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" name="helmet">
<xs:complexType>
<xs:sequence>
<xs:element ref="location"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="torse">
<xs:complexType>
<xs:sequence>
<xs:element ref="location"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" name="mantling">
<xs:complexType>
<xs:sequence>
<xs:element maxOccurs="unbounded" ref="location"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" name="supporters">
<xs:annotation>
<xs:documentation/>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:element ref="location"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" name="motto">
<xs:annotation>
<xs:documentation/>
</xs:annotation>
<xs:complexType>
<xs:attributeGroup ref="common"/>
<xs:attribute name="text" type="xs:string"/>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element ref="instructions" minOccurs="0"/>
<xs:element minOccurs="0" name="messages">
<xs:complexType>
<xs:sequence>
<xs:element maxOccurs="unbounded" name="message">
<xs:annotation>
<xs:documentation>Content is free form error message</xs:documentation>
</xs:annotation>
<xs:complexType mixed="true">
<xs:sequence>
<xs:any/>
</xs:sequence>
<xs:attribute name="category" type="xs:Name"/>
<xs:attribute name="context" type="xs:string"/>
<xs:attribute name="filename" type="xs:string"/>
<xs:attribute name="linerange" type="xs:string"/>
<xs:attribute ref="tokens"/>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
<xs:attribute name="blazonText" use="required" type="xs:string">
<xs:annotation>
<xs:documentation>DEPRECATED - prefer the input element </xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="blazonTokens" use="required">
<xs:annotation>
<xs:documentation>This is a blank separated list of tokens created by the lexical analyser. The "tokens" attributes of other elements are zero based references to this list.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="schemaVersion" fixed="1.1"/>
<xs:attribute name="creatorName">
<xs:annotation>
<xs:documentation>Free format string for use of the program that generated this xml</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="timestamp">
<xs:simpleType>
<xs:restriction base="xs:string"/>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="creatorVersion"/>
</xs:complexType>
</xs:element>
<xs:element name="shield">
<xs:complexType>
<xs:sequence minOccurs="0">
<xs:choice maxOccurs="1">
<xs:element name="simple">
<xs:complexType>
<xs:sequence>
<xs:element minOccurs="0" name="chief">
<xs:complexType>
<xs:sequence>
<xs:element ref="ordinary">
<xs:annotation>
<xs:documentation>The only ordinary valid here is the chief (NOT chief triangular). Note that with the "chief voided [tincture]" the field should NOT be rendered in a reduced area, but the charges SHOULD </xs:documentation>
</xs:annotation>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="field">
<xs:complexType>
<xs:sequence>
<xs:element ref="tincture"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element ref="objects" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="complex">
<xs:complexType>
<xs:sequence>
<xs:element ref="shield" maxOccurs="unbounded"/>
</xs:sequence>
<xs:attribute name="order">
<xs:annotation>
<xs:documentation>keyterm determines the type of multiple shield, order shows many portions (where this is not fixed)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element ref="missing"/>
<xs:element name="pending">
<xs:annotation>
<xs:documentation>This represents a quartering that is required but not been provided. It is up the implementor how this is handled.</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
</xs:choice>
<xs:element minOccurs="0" ref="overall"/>
</xs:sequence>
<xs:attribute name="index">
<xs:annotation>
<xs:documentation>If on a divided shield, the index gives the ordering of sub shields (numerical order, left to right, top to bottom)</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="overall">
<xs:complexType>
<xs:sequence>
<xs:element ref="objects"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="tincture">
<xs:complexType>
<xs:sequence minOccurs="0">
<xs:element ref="instructions"/>
<xs:choice>
<xs:element name="proper">
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element ref="colour"/>
<xs:element name="fur">
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="treatment">
<xs:complexType>
<xs:sequence>
<xs:element ref="tincture"/>
<xs:element ref="tincture"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="semyDe">
<xs:complexType>
<xs:sequence>
<xs:element ref="tincture"/>
<xs:choice>
<xs:element ref="charge"/>
<xs:element ref="missing"/>
</xs:choice>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element ref="counterChanged"/>
<xs:element ref="division"/>
</xs:choice>
</xs:sequence>
<xs:attribute default="1" name="index" type="xs:nonNegativeInteger" use="optional"/>
<xs:attribute name="origin">
<xs:annotation>
<xs:documentation>This is the "origin" of the tincture, i.e. where it came from. See the enumerations for details of each. It is possible that in future the elements "proper" and "implied" may be replaced by this attribute.</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="given">
<xs:annotation>
<xs:documentation>This tincture was explicitly supplied in the blazon, in the expected place.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="default">
<xs:annotation>
<xs:documentation>No explicit tincture was given but the charge has a default tincture, for example an ermine tail is sable unless otherwise given.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="pending">
<xs:annotation>
<xs:documentation>This tincture was explicitly given but later in the blazon, possibly shared with another charge for example.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="proper">
<xs:annotation>
<xs:documentation>This charge is always the same tincture, and may only be given the explicit tincture "proper".</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="implied"/>
<xs:enumeration value="missing"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="division">
<xs:complexType>
<xs:sequence>
<xs:choice>
<xs:element minOccurs="0" ref="counterChanged"/>
<xs:element maxOccurs="unbounded" minOccurs="0" ref="modifier"/>
<xs:element ref="tincture" maxOccurs="unbounded"/>
</xs:choice>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="charge">
<xs:annotation>
<xs:documentation/>
</xs:annotation>
<xs:complexType>
<xs:sequence minOccurs="0">
<xs:element ref="tincture" minOccurs="0"/>
<xs:choice minOccurs="0">
<xs:element maxOccurs="unbounded" ref="modifier" minOccurs="0"/>
</xs:choice>
</xs:sequence>
<xs:attribute name="number" use="required"/>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="ordinary">
<xs:complexType>
<xs:sequence>
<xs:element ref="tincture"/>
<xs:element minOccurs="0" ref="tincture"/>
<xs:choice minOccurs="0">
<xs:element maxOccurs="unbounded" minOccurs="0" ref="modifier"/>
</xs:choice>
</xs:sequence>
<xs:attribute name="number" type="xs:positiveInteger"/>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="objects">
<xs:annotation>
<xs:documentation>Although any division is allowed by the schema,the parser should ensure that ONLY divisions which are counterchanged should be permitted</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:choice maxOccurs="unbounded">
<xs:element maxOccurs="unbounded" minOccurs="0" ref="charge"/>
<xs:element maxOccurs="unbounded" minOccurs="0" ref="ordinary"/>
<xs:element ref="division"/>
</xs:choice>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="colour">
<xs:complexType>
<xs:attributeGroup ref="common"/>
<xs:attribute name="spec">
<xs:annotation>
<xs:documentation>For drawing use, the colour code</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
</xs:element>
<xs:element name="modifier">
<xs:complexType>
<xs:sequence minOccurs="0">
<xs:choice minOccurs="0">
<xs:element ref="tincture"/>
<xs:element ref="charge"/>
<xs:element ref="missing"/>
<xs:element ref="shield"/>
<xs:element ref="ordinary"/>
<xs:element ref="modifier"/>
</xs:choice>
</xs:sequence>
<xs:attribute name="type"/>
<xs:attribute name="value"/>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="missing">
<xs:annotation>
<xs:documentation>This indicates that the parser was unable to find a required element. It is up to the implementor how this is represented graphically</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="instructions">
<xs:complexType>
<xs:sequence>
<xs:choice maxOccurs="unbounded">
<xs:element name="shape" minOccurs="0">
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" name="palette">
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element minOccurs="0" name="effect">
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="aspect" minOccurs="0">
<xs:annotation>
<xs:documentation>Only meaningful if shape is "flag"</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="comments" minOccurs="0">
<xs:complexType>
<xs:sequence>
<xs:any namespace="##any"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:choice>
</xs:sequence>
<xs:attribute name="source"/>
</xs:complexType>
</xs:element>
<xs:attributeGroup name="common">
<xs:attribute ref="tokens"/>
<xs:attribute name="linenumber" type="xs:string"/>
<xs:attribute name="keyterm" type="xs:Name"/>
<xs:attribute ref="IDREF"/>
<xs:attribute name="link" type="xs:anyURI"/>
<xs:attribute name="ID" type="xs:ID" use="required"/>
<xs:attribute ref="annotation"/>
<xs:attribute name="renderinfo" type="xs:string">
<xs:annotation>
<xs:documentation>This may be used as required by the renderer, for example to contain placement information of usage flags</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:attributeGroup>
<xs:attribute name="tokens" type="xs:string">
<xs:annotation>
<xs:documentation>This is the sequence of tokens that were "consumed" by the parsing process in reading this tincture. It may be empty if the tincture is implied, or is part of a larger structure.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="annotation" type="xs:string">
<xs:annotation>
<xs:documentation>Notes from the Herald's knowledge</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="IDREF" type="xs:IDREF">
<xs:annotation>
<xs:documentation>If an element has an IDREF all additional content is optional. If present the additional content "overrides" that from the referred element.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:element name="counterChanged">
<xs:complexType>
<xs:sequence>
<xs:element ref="division"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
</xs:complexType>
</xs:element>
<xs:element name="location">
<xs:complexType>
<xs:sequence maxOccurs="2" minOccurs="0">
<xs:element ref="tincture"/>
</xs:sequence>
<xs:attributeGroup ref="common"/>
<xs:attribute name="name">
<xs:annotation>
<xs:documentation>typically just sinister/dexter, but absence denotes the "normal" location</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
</xs:element>
</xs:schema>