-
Notifications
You must be signed in to change notification settings - Fork 0
/
Chuki.xsd
227 lines (220 loc) · 7.47 KB
/
Chuki.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
<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="Chuki"
targetNamespace="https://github.com/kurema/AozoraGaijiChukiXml/blob/master/data/Chuki.xsd"
elementFormDefault="qualified"
xmlns="https://github.com/kurema/AozoraGaijiChukiXml/blob/master/data/Chuki.xsd"
xmlns:mstns="https://github.com/kurema/AozoraGaijiChukiXml/blob/master/data/Chuki.xsd"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
>
<xs:element name="dictionary">
<xs:complexType>
<xs:sequence>
<xs:element name="kanji">
<xs:complexType>
<xs:sequence minOccurs="0" maxOccurs="unbounded">
<xs:element ref="mstns:page" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="other">
<xs:complexType>
<xs:sequence minOccurs="0" maxOccurs="unbounded">
<xs:element ref="mstns:PageOther" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="toc">
<xs:complexType>
<xs:sequence>
<xs:element name="strokesToRadical">
<xs:complexType>
<xs:sequence minOccurs="0" maxOccurs="unbounded">
<xs:element name="strokes">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute name="stroke" type="xs:int"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="page">
<xs:complexType>
<xs:sequence>
<xs:element name="radical">
<xs:complexType>
<xs:sequence>
<xs:element name="readings">
<xs:complexType>
<xs:sequence minOccurs="0" maxOccurs="unbounded">
<xs:element name="reading" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="characters">
<xs:complexType>
<xs:sequence minOccurs="0" maxOccurs="unbounded">
<xs:element name="character" type="xs:string" />
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="entries">
<xs:complexType>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="mstns:entry" />
</xs:choice>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="PageOther">
<xs:complexType>
<xs:sequence>
<xs:element name="header" type="xs:string"/>
<xs:element ref="mstns:PageOther" minOccurs="0" maxOccurs="unbounded" />
<xs:element name="entries">
<xs:complexType>
<xs:sequence>
<xs:element name="entry" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="character" type="xs:string" />
<xs:element ref="mstns:note" minOccurs="0"/>
<xs:element name="info" type="xs:string" minOccurs="0"/>
</xs:sequence>
<xs:attribute name="docPage" type="xs:nonNegativeInteger" default="0" />
<xs:attribute name="inputable" use="optional" type="xs:boolean" default="false" />
<!--<xs:attribute ref="mstns:supplement"/>-->
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="entry">
<xs:complexType>
<xs:sequence>
<xs:element name="characters">
<xs:complexType>
<xs:sequence minOccurs="0" maxOccurs="unbounded">
<xs:element name="character" type="mstns:singleCharacter" />
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:choice minOccurs="0">
<xs:element name="inputable"/>
<xs:element name="designVariant">
<xs:complexType>
<xs:attribute name="ref" type="mstns:singleCharacter" />
</xs:complexType>
</xs:element>
<xs:element name="inclusionApplication">
<xs:annotation>
<xs:documentation>包摂適用</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:sequence>
<xs:choice>
<xs:element ref="mstns:note" />
<xs:element name="character" type="mstns:singleCharacter"/>
</xs:choice>
<xs:element name="reference" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="page" type="xs:positiveInteger" />
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="integrationApplication">
<xs:annotation>
<xs:documentation>統合適用</xs:documentation>
</xs:annotation>
<xs:complexType>
<xs:choice>
<xs:element ref="mstns:note" />
<xs:element name="character" type="mstns:singleCharacter"/>
</xs:choice>
</xs:complexType>
</xs:element>
<xs:element name="Compatible78Inclusion">
<xs:annotation>
<xs:documentation>78互換包摂</xs:documentation>
</xs:annotation>
<xs:complexType>
<!--<xs:choice minOccurs="0">
<xs:element ref="mstns:note" />
</xs:choice>-->
<xs:attribute name="ref" type="mstns:singleCharacter" />
</xs:complexType>
</xs:element>
</xs:choice>
<xs:element ref="mstns:note" minOccurs="0" />
<xs:element name="UCV" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="number" type="xs:nonNegativeInteger"/>
</xs:complexType>
</xs:element>
</xs:sequence>
<xs:attribute name="refPage" type="xs:nonNegativeInteger" default="0"/>
<xs:attribute name="docPage" type="xs:nonNegativeInteger" default="0" />
<xs:attribute type="xs:nonNegativeInteger" name="strokes" />
<xs:attribute type="xs:boolean" name="duplicate" default="false" />
<xs:attribute ref="mstns:supplement"/>
</xs:complexType>
</xs:element>
<xs:attribute name="supplement" default="default">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="supplementOnly" />
<xs:enumeration value="supplementCommon" />
<xs:enumeration value="default" />
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:element name="note">
<xs:complexType>
<xs:sequence>
<xs:element name="pre" type="xs:string" minOccurs="0"/>
<xs:element name="full" type="xs:string"/>
<xs:element name="description" type="xs:string"/>
<xs:choice minOccurs="0">
<xs:element name="jisx0213" >
<xs:complexType>
<xs:attribute name="level" type="xs:int"/>
<xs:attribute name="men" type="xs:int"/>
<xs:attribute name="ku" type="xs:int"/>
<xs:attribute name="ten" type="xs:int"/>
</xs:complexType>
</xs:element>
<xs:element name="unicode" >
<xs:complexType>
<xs:attribute name="code" type="xs:string"/>
</xs:complexType>
</xs:element>
</xs:choice>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:simpleType name="singleCharacter">
<xs:restriction base="xs:string" >
<!--<xs:length value="1" />-->
<!-- サロゲートペアを考えると一文字に指定しない方が賢明。 -->
</xs:restriction>
</xs:simpleType>
</xs:schema>