|
9 | 9 | License: Creative Commons Attribution-NoDerivatives 4.0 International Public License |
10 | 10 | </xs:documentation> |
11 | 11 | </xs:annotation> |
| 12 | + <!-- Elements --> |
12 | 13 | <xs:element name="messageSchema"> |
13 | 14 | <xs:annotation> |
14 | 15 | <xs:documentation> |
|
29 | 30 | </xs:annotation> |
30 | 31 | <xs:complexType> |
31 | 32 | <xs:choice maxOccurs="unbounded"> |
32 | | - <xs:element name="type" type="sbe:encodedDataType"/> |
| 33 | + <xs:element name="type" type="sbe:simpleDataType"/> |
33 | 34 | <xs:element name="composite" type="sbe:compositeDataType"/> |
34 | 35 | <xs:element name="enum" type="sbe:enumType"/> |
35 | 36 | <xs:element name="set" type="sbe:setType"/> |
|
86 | 87 | </xs:documentation> |
87 | 88 | </xs:annotation> |
88 | 89 | </xs:element> |
| 90 | + <!-- Complex types --> |
89 | 91 | <xs:complexType name="blockType"> |
90 | 92 | <xs:annotation> |
91 | 93 | <xs:documentation>Base type of message and repeating group entry |
|
133 | 135 | </xs:extension> |
134 | 136 | </xs:complexContent> |
135 | 137 | </xs:complexType> |
136 | | - <xs:complexType name="encodedDataType" mixed="true"> |
| 138 | + <xs:complexType name="simpleDataType" mixed="true"> |
137 | 139 | <xs:annotation> |
138 | 140 | <xs:documentation> |
139 | 141 | Simple wire encoding consisting of a primitive type |
|
144 | 146 | <xs:extension base="xs:token"> |
145 | 147 | <xs:attribute name="name" type="sbe:symbolicName_t" use="required"/> |
146 | 148 | <xs:attribute name="description" type="xs:string" use="optional"/> |
147 | | - <xs:attribute name="length" type="xs:nonNegativeInteger" default="1"/> |
148 | | - <xs:attribute name="primitiveType" use="required"> |
149 | | - <xs:simpleType> |
150 | | - <xs:restriction base="xs:token"> |
151 | | - <xs:enumeration value="char"> |
152 | | - <xs:annotation> |
153 | | - <xs:documentation>A value of a single-byte character set</xs:documentation> |
154 | | - </xs:annotation> |
155 | | - </xs:enumeration> |
156 | | - <xs:enumeration value="int8"/> |
157 | | - <xs:enumeration value="int16"/> |
158 | | - <xs:enumeration value="int32"/> |
159 | | - <xs:enumeration value="int64"/> |
160 | | - <xs:enumeration value="uint8"/> |
161 | | - <xs:enumeration value="uint16"/> |
162 | | - <xs:enumeration value="uint32"/> |
163 | | - <xs:enumeration value="uint64"/> |
164 | | - <xs:enumeration value="float"/> |
165 | | - <xs:enumeration value="double"/> |
166 | | - </xs:restriction> |
167 | | - </xs:simpleType> |
168 | | - </xs:attribute> |
169 | | - <xs:attribute name="characterEncoding" type="xs:string" use="optional"> |
170 | | - <xs:annotation> |
171 | | - <xs:documentation>Character set or Unicode encoding scheme</xs:documentation> |
172 | | - </xs:annotation> |
173 | | - </xs:attribute> |
174 | | - <xs:attributeGroup ref="sbe:alignmentAttributes"/> |
175 | | - <xs:attributeGroup ref="sbe:presenceAttributes"> |
176 | | - <xs:annotation> |
177 | | - <xs:documentation>Presence only applies within a composite type</xs:documentation> |
178 | | - </xs:annotation> |
179 | | - </xs:attributeGroup> |
| 149 | + <xs:attributeGroup ref="sbe:primitiveTypeAttributes"/> |
180 | 150 | <xs:attributeGroup ref="sbe:versionAttributes"/> |
181 | 151 | </xs:extension> |
182 | 152 | </xs:simpleContent> |
183 | 153 | </xs:complexType> |
| 154 | + <xs:complexType name="memberDataType" mixed="true"> |
| 155 | + <xs:annotation> |
| 156 | + <xs:documentation> |
| 157 | + A simple type used as a member of a composite type |
| 158 | + </xs:documentation> |
| 159 | + </xs:annotation> |
| 160 | + <xs:simpleContent> |
| 161 | + <xs:extension base="xs:token"> |
| 162 | + <xs:attribute name="name" type="sbe:symbolicName_t" use="required"/> |
| 163 | + <xs:attribute name="description" type="xs:string" use="optional"/> |
| 164 | + <xs:attributeGroup ref="sbe:primitiveTypeAttributes"/> |
| 165 | + <xs:attributeGroup ref="sbe:alignmentAttributes"/> |
| 166 | + <xs:attributeGroup ref="sbe:presenceAttributes"/> |
| 167 | + </xs:extension> |
| 168 | + </xs:simpleContent> |
| 169 | + </xs:complexType> |
184 | 170 | <xs:complexType name="compositeDataType" mixed="true"> |
185 | 171 | <xs:annotation> |
186 | 172 | <xs:documentation> |
187 | 173 | A wire encoding composed of multiple parts |
188 | 174 | </xs:documentation> |
189 | 175 | </xs:annotation> |
190 | 176 | <xs:choice maxOccurs="unbounded"> |
191 | | - <xs:element name="type" type="sbe:encodedDataType"/> |
| 177 | + <xs:element name="type" type="sbe:memberDataType"/> |
192 | 178 | <xs:element name="enum" type="sbe:enumType"/> |
193 | 179 | <xs:element name="set" type="sbe:setType"/> |
194 | 180 | <xs:element name="composite" type="sbe:compositeDataType"/> |
|
238 | 224 | <xs:attribute name="name" type="sbe:symbolicName_t" use="required"/> |
239 | 225 | <xs:attribute name="type" type="sbe:symbolicName_t" use="required"/> |
240 | 226 | <xs:attributeGroup ref="sbe:alignmentAttributes"/> |
241 | | - <xs:attributeGroup ref="sbe:versionAttributes"/> |
242 | 227 | </xs:complexType> |
243 | 228 | <xs:complexType name="setType" mixed="true"> |
244 | 229 | <xs:annotation> |
|
290 | 275 | <xs:attributeGroup ref="sbe:semanticAttributes"/> |
291 | 276 | <xs:attributeGroup ref="sbe:versionAttributes"/> |
292 | 277 | </xs:complexType> |
293 | | - <xs:attributeGroup name="semanticAttributes"> |
294 | | - <xs:annotation> |
295 | | - <xs:documentation> |
296 | | - Application layer class. Maps a field to a FIX data type or a template to a FIX message. |
297 | | - </xs:documentation> |
298 | | - </xs:annotation> |
299 | | - <xs:attribute name="semanticType" type="xs:token" use="optional"/> |
300 | | - <xs:attribute name="description" type="xs:string" use="optional"/> |
301 | | - </xs:attributeGroup> |
302 | | - <xs:attributeGroup name="versionAttributes"> |
303 | | - <xs:annotation> |
304 | | - <xs:documentation> |
305 | | - Schema versioning supports message extension |
306 | | - </xs:documentation> |
307 | | - </xs:annotation> |
308 | | - <xs:attribute name="sinceVersion" type="xs:nonNegativeInteger" default="0"> |
309 | | - <xs:annotation> |
310 | | - <xs:documentation> |
311 | | - The schema version in which an element was added |
312 | | - </xs:documentation> |
313 | | - </xs:annotation> |
314 | | - </xs:attribute> |
315 | | - <xs:attribute name="deprecated" type="xs:nonNegativeInteger" use="optional"> |
316 | | - <xs:annotation> |
317 | | - <xs:documentation> |
318 | | - The version of the schema in which an element was deprecated. It is retained |
319 | | - for back compatibility but should no longer be used by updated applications. |
320 | | - It may be removed in a later version. |
321 | | - </xs:documentation> |
322 | | - </xs:annotation> |
323 | | - </xs:attribute> |
324 | | - </xs:attributeGroup> |
| 278 | + <!-- Simple types --> |
| 279 | + <xs:simpleType name="qualifiedName_t"> |
| 280 | + <xs:restriction base="xs:string"> |
| 281 | + <xs:pattern value="([A-Z]|[a-z]|_)([0-9]|[A-Z]|[a-z]|_)*\.([A-Z]|[a-z]|_)([0-9]|[A-Z]|[a-z]|_)*"/> |
| 282 | + </xs:restriction> |
| 283 | + </xs:simpleType> |
| 284 | + <xs:simpleType name="symbolicName_t"> |
| 285 | + <xs:restriction base="xs:string"> |
| 286 | + <xs:minLength value="1"/> |
| 287 | + <xs:maxLength value="64"/> |
| 288 | + <xs:pattern value="([A-Z]|[a-z]|_)([0-9]|[A-Z]|[a-z]|_)*"/> |
| 289 | + </xs:restriction> |
| 290 | + </xs:simpleType> |
| 291 | + <!-- Attribute groups --> |
325 | 292 | <xs:attributeGroup name="alignmentAttributes"> |
326 | 293 | <xs:attribute name="offset" type="xs:unsignedInt" use="optional"> |
327 | 294 | <xs:annotation> |
|
382 | 349 | </xs:annotation> |
383 | 350 | </xs:attribute> |
384 | 351 | </xs:attributeGroup> |
385 | | - <xs:simpleType name="symbolicName_t"> |
386 | | - <xs:restriction base="xs:string"> |
387 | | - <xs:minLength value="1"/> |
388 | | - <xs:maxLength value="64"/> |
389 | | - <xs:pattern value="([A-Z]|[a-z]|_)([0-9]|[A-Z]|[a-z]|_)*"/> |
390 | | - </xs:restriction> |
391 | | - </xs:simpleType> |
392 | | - <xs:simpleType name="qualifiedName_t"> |
393 | | - <xs:restriction base="xs:string"> |
394 | | - <xs:pattern value="([A-Z]|[a-z]|_)([0-9]|[A-Z]|[a-z]|_)*\.([A-Z]|[a-z]|_)([0-9]|[A-Z]|[a-z]|_)*"/> |
395 | | - </xs:restriction> |
396 | | - </xs:simpleType> |
| 352 | + <xs:attributeGroup name="primitiveTypeAttributes"> |
| 353 | + <xs:attribute name="primitiveType" use="required"> |
| 354 | + <xs:simpleType> |
| 355 | + <xs:restriction base="xs:token"> |
| 356 | + <xs:enumeration value="char"> |
| 357 | + <xs:annotation> |
| 358 | + <xs:documentation>A value of a single-byte character set</xs:documentation> |
| 359 | + </xs:annotation> |
| 360 | + </xs:enumeration> |
| 361 | + <xs:enumeration value="int8"/> |
| 362 | + <xs:enumeration value="int16"/> |
| 363 | + <xs:enumeration value="int32"/> |
| 364 | + <xs:enumeration value="int64"/> |
| 365 | + <xs:enumeration value="uint8"/> |
| 366 | + <xs:enumeration value="uint16"/> |
| 367 | + <xs:enumeration value="uint32"/> |
| 368 | + <xs:enumeration value="uint64"/> |
| 369 | + <xs:enumeration value="float"/> |
| 370 | + <xs:enumeration value="double"/> |
| 371 | + </xs:restriction> |
| 372 | + </xs:simpleType> |
| 373 | + </xs:attribute> |
| 374 | + <xs:attribute name="length" type="xs:nonNegativeInteger" default="1"/> |
| 375 | + <xs:attribute name="characterEncoding" type="xs:string" use="optional"> |
| 376 | + <xs:annotation> |
| 377 | + <xs:documentation>Character set or Unicode encoding scheme</xs:documentation> |
| 378 | + </xs:annotation> |
| 379 | + </xs:attribute> |
| 380 | + </xs:attributeGroup> |
| 381 | + <xs:attributeGroup name="semanticAttributes"> |
| 382 | + <xs:annotation> |
| 383 | + <xs:documentation> |
| 384 | + Application layer class. Maps a field to a FIX data type or a template to a FIX message. |
| 385 | + </xs:documentation> |
| 386 | + </xs:annotation> |
| 387 | + <xs:attribute name="semanticType" type="xs:token" use="optional"/> |
| 388 | + <xs:attribute name="description" type="xs:string" use="optional"/> |
| 389 | + </xs:attributeGroup> |
| 390 | + <xs:attributeGroup name="versionAttributes"> |
| 391 | + <xs:annotation> |
| 392 | + <xs:documentation> |
| 393 | + Schema versioning supports message extension |
| 394 | + </xs:documentation> |
| 395 | + </xs:annotation> |
| 396 | + <xs:attribute name="sinceVersion" type="xs:nonNegativeInteger" default="0"> |
| 397 | + <xs:annotation> |
| 398 | + <xs:documentation> |
| 399 | + The schema version in which an element was added |
| 400 | + </xs:documentation> |
| 401 | + </xs:annotation> |
| 402 | + </xs:attribute> |
| 403 | + <xs:attribute name="deprecated" type="xs:nonNegativeInteger" use="optional"> |
| 404 | + <xs:annotation> |
| 405 | + <xs:documentation> |
| 406 | + The version of the schema in which an element was deprecated. It is retained |
| 407 | + for back compatibility but should no longer be used by updated applications. |
| 408 | + It may be removed in a later version. |
| 409 | + </xs:documentation> |
| 410 | + </xs:annotation> |
| 411 | + </xs:attribute> |
| 412 | + </xs:attributeGroup> |
397 | 413 | </xs:schema> |
0 commit comments