source: josm/trunk/data/tagging-preset.xsd@ 6308

Last change on this file since 6308 was 6308, checked in by Don-vip, 11 years ago

fix tabs in tagging preset XSD

  • Property svn:mime-type set to text/plain
File size: 9.1 KB
RevLine 
[3321]1<?xml version="1.0" encoding="UTF-8"?>
2<schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://josm.openstreetmap.de/tagging-preset-1.0"
[3839]3 xmlns:tns="http://josm.openstreetmap.de/tagging-preset-1.0"
4 elementFormDefault="qualified">
[3321]5
[4431]6 <!-- Localized attributes (for example de.description are not supported
7 by xsd, so every element needs <anyAttribute/> To cover at least some common
[3839]8 errors, elements have specified prohibited attributes -->
[3321]9
[3839]10 <element name="annotations" type="tns:root" />
11 <element name="presets" type="tns:root" />
[3321]12
13 <complexType name="root">
14 <complexContent>
[3839]15 <extension base="tns:group-parent">
[3321]16 <attribute name="author" type="string" />
17 <attribute name="version" type="string" />
18 <attribute name="shortdescription" type="string" />
19 <attribute name="description" type="string" />
[3839]20 <attribute name="link" type="string" />
[3321]21
[3839]22 <anyAttribute processContents="skip" />
[3321]23 </extension>
24 </complexContent>
25 </complexType>
26
[3839]27 <complexType name="group-parent">
[3321]28 <sequence>
29 <choice minOccurs="1" maxOccurs="unbounded">
30 <element name="group" type="tns:group" />
31 <element name="item" type="tns:item" />
32 <element name="separator" type="tns:separator" />
33 </choice>
34 </sequence>
35 <attribute name="icon" type="string" />
36
[3839]37 <attribute name="type" use="prohibited" />
38 <attribute name="text" use="prohibited" />
39 <anyAttribute processContents="skip" />
[3321]40 </complexType>
41
[3839]42 <complexType name="group">
43 <complexContent>
44 <extension base="tns:group-parent">
45 <attribute name="name" type="string" use="required" />
46 </extension>
47 </complexContent>
48 </complexType>
49
[3321]50 <complexType name="separator" />
51
52 <complexType name="item">
53 <sequence>
54 <choice minOccurs="0" maxOccurs="unbounded">
55 <group ref="tns:optional_elements" />
56 <element name="key" type="tns:key" />
57 <element name="optional" type="tns:optional" minOccurs="0" />
58 </choice>
[5614]59 <element name="roles" type="tns:roles" minOccurs="0" maxOccurs="1" />
[3321]60 </sequence>
[3839]61 <attribute name="name" type="string" use="required" />
[3321]62 <attribute name="icon" type="string" />
63 <attribute name="type" type="string" />
[4431]64 <attribute name="name_template" type="string"/>
65 <attribute name="name_template_filter" type="string"/>
[3321]66
[3839]67 <attribute name="text" use="prohibited" />
68 <anyAttribute processContents="skip" />
[3321]69 </complexType>
70
71 <complexType name="optional">
72 <group ref="tns:optional_elements" maxOccurs="unbounded" />
[6308]73 <attribute name="text" type="string" />
74 <attribute name="text_context" type="string" />
[3321]75 </complexType>
76
77 <group name="optional_elements">
78 <choice>
79 <element name="label" type="tns:label" />
80 <element name="space" type="tns:space" />
81 <element name="link" type="tns:link" />
82 <element name="text" type="tns:text" />
83 <element name="combo" type="tns:combo" />
[3793]84 <element name="multiselect" type="tns:multiselect" />
[6308]85 <element name="checkgroup" type="tns:checkgroup" />
[3321]86 <element name="check" type="tns:check" />
[6198]87 <element name="item_separator" type="tns:separator" />
[3321]88 </choice>
89 </group>
90
91 <complexType name="key">
[3839]92 <attribute name="key" type="string" use="required" />
93 <attribute name="value" type="string" />
[5157]94 <attribute name="match" type="string" />
[3321]95 </complexType>
96
97
98 <complexType name="link">
99 <attribute name="href" type="string" use="required" />
100 <attribute name="text" type="string" />
[3582]101 <attribute name="text_context" type="string" />
[3321]102
[3839]103 <attribute name="name" use="prohibited" />
104 <anyAttribute processContents="skip" />
[3321]105 </complexType>
106
107 <complexType name="label">
108 <attribute name="text" type="string" use="required" />
[3582]109 <attribute name="text_context" type="string" />
[3321]110
[3839]111 <attribute name="name" use="prohibited" />
112 <anyAttribute processContents="skip" />
[3321]113 </complexType>
114
115 <complexType name="space" />
116
117 <complexType name="text">
[3839]118 <attribute name="key" type="string" use="required" />
[3321]119 <attribute name="text" type="string" />
[3582]120 <attribute name="text_context" type="string" />
[3321]121 <attribute name="default" type="string" />
[4218]122 <attribute name="use_last_as_default" type="tns:last_default" />
[5639]123 <attribute name="auto_increment" type="string" />
[5157]124 <attribute name="match" type="tns:match" />
[5997]125 <attribute name="length" type="positiveInteger" />
[3321]126
[3839]127 <attribute name="type" use="prohibited" />
128 <attribute name="name" use="prohibited" />
129 <attribute name="value" use="prohibited" />
130 <attribute name="values" use="prohibited" />
131 <anyAttribute processContents="skip" />
[3321]132 </complexType>
133
[5180]134 <complexType name="list_entry">
[5158]135 <attribute name="value" type="string" use="required" />
[5180]136 <attribute name="value_context" type="string" />
[5158]137 <attribute name="display_value" type="string" />
138 <attribute name="short_description" type="string" />
139 <attribute name="icon" type="string" />
[5585]140 <attribute name="icon_size" type="integer" />
[5722]141 <anyAttribute processContents="skip" />
[5158]142 </complexType>
143
[3321]144 <complexType name="combo">
[5158]145 <!-- use either list_entry's or a combination of values/display_values -->
[3741]146 <sequence>
[5158]147 <element name="list_entry" type="tns:list_entry" minOccurs="0" maxOccurs="unbounded" />
[3741]148 </sequence>
[3321]149 <attribute name="key" type="string" use="required" />
150 <attribute name="text" type="string" />
[3582]151 <attribute name="text_context" type="string" />
[5158]152 <attribute name="values" type="string" />
[6055]153 <attribute name="values_from" type="string" />
[3582]154 <attribute name="values_context" type="string" />
[3839]155 <attribute name="display_values" type="string" />
[3321]156 <attribute name="default" type="string" />
[4218]157 <attribute name="use_last_as_default" type="tns:last_default" />
[6308]158 <attribute name="delimiter" type="string" />
[3321]159 <attribute name="editable" type="boolean" />
[5157]160 <attribute name="match" type="tns:match" />
[5997]161 <attribute name="length" type="positiveInteger" />
[3321]162
[3839]163 <attribute name="type" use="prohibited" />
164 <attribute name="value" use="prohibited" />
165 <attribute name="name" use="prohibited" />
166 <attribute name="delete-if-empty" use="prohibited" />
167 <attribute name="display-values" use="prohibited" />
168 <anyAttribute processContents="skip" />
[3321]169 </complexType>
170
[3793]171 <complexType name="multiselect">
[6308]172 <!-- use either list_entry's or a combination of values/display_values -->
173 <sequence>
174 <element name="list_entry" type="tns:list_entry" minOccurs="0" maxOccurs="unbounded" />
175 </sequence>
[3793]176 <attribute name="key" type="string" use="required" />
177 <attribute name="text" type="string" />
178 <attribute name="text_context" type="string" />
[6055]179 <attribute name="values" type="string" />
180 <attribute name="values_from" type="string" />
[3793]181 <attribute name="values_context" type="string" />
[3839]182 <attribute name="display_values" type="string" />
[3793]183 <attribute name="default" type="string" />
[4218]184 <attribute name="use_last_as_default" type="tns:last_default" />
[3793]185 <attribute name="delimiter" type="string" />
[5157]186 <attribute name="match" type="tns:match" />
[3793]187
[3839]188 <attribute name="type" use="prohibited" />
189 <attribute name="value" use="prohibited" />
190 <attribute name="name" use="prohibited" />
191 <attribute name="delete-if-empty" use="prohibited" />
192 <attribute name="display-values" use="prohibited" />
193 <anyAttribute processContents="skip" />
[3793]194 </complexType>
195
[6308]196 <complexType name="checkgroup">
197 <sequence>
198 <choice minOccurs="1" maxOccurs="unbounded">
199 <element name="check" type="tns:check" />
200 </choice>
201 </sequence>
202 <attribute name="columns" type="positiveInteger" />
203 <anyAttribute processContents="skip" />
204 </complexType>
[6114]205
[3321]206 <complexType name="check">
207 <attribute name="key" type="string" use="required" />
208 <attribute name="text" type="string" />
[3582]209 <attribute name="text_context" type="string" />
[3321]210 <attribute name="default" type="tns:check_default" />
[3839]211 <attribute name="value_on" type="string" />
212 <attribute name="value_off" type="string" />
[5157]213 <attribute name="match" type="tns:match" />
[3321]214
[3839]215 <attribute name="name" use="prohibited" />
216 <attribute name="type" use="prohibited" />
217 <attribute name="value" use="prohibited" />
218 <anyAttribute processContents="skip" />
[3321]219 </complexType>
220
221 <simpleType name="check_default">
222 <restriction base="string">
223 <enumeration value="on" />
224 <enumeration value="off" />
225 </restriction>
226 </simpleType>
227
[4218]228 <simpleType name="last_default">
229 <restriction base="string">
230 <enumeration value="true" />
231 <enumeration value="false" />
232 <enumeration value="force" />
233 </restriction>
234 </simpleType>
235
[5157]236 <simpleType name="match">
237 <restriction base="string">
238 <enumeration value="none" />
239 <enumeration value="key" />
240 <enumeration value="key!" />
241 <enumeration value="keyvalue" />
242 </restriction>
243 </simpleType>
244
[3321]245 <complexType name="roles">
246 <sequence>
[3839]247 <element name="role" type="tns:role" minOccurs="1" maxOccurs="unbounded" />
[3321]248 </sequence>
249 </complexType>
250
251 <complexType name="role">
[3839]252 <attribute name="key" type="string" />
253 <attribute name="text" type="string" />
254 <attribute name="text_context" type="string" />
255 <attribute name="requisite" type="tns:role_requisite" />
256 <attribute name="type" type="string" />
257 <attribute name="count" type="integer" />
[5614]258 <attribute name="member_expression" type="string" />
[5760]259 <anyAttribute processContents="skip" />
[3321]260 </complexType>
261
262 <simpleType name="role_requisite">
263 <restriction base="string">
[3839]264 <enumeration value="required" />
265 <enumeration value="optional" />
[3321]266 </restriction>
267 </simpleType>
268
[3533]269</schema>
Note: See TracBrowser for help on using the repository browser.