summaryrefslogtreecommitdiff
path: root/java/joelib2/io/types/cml/data/cml1_0_1.dtd
blob: 706b1abeb6ab10c54e5cbc7e50d1e1771b74d213 (plain)
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
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
<!-- CML V1.01 DTD -->
<!-- Amendments and errata from V1. (1999-05-15) -->
<!-- Authors:
 P.Murray-Rust
 H.Rzepa
This DTD is fully described in  P. Murray-Rust and H. S. Rzepa, Journal of Chem
ical Information
 and Computer Science,  1999, 39, 928. 
-->
<!-- Changes (2001-04-06):
1.      atomRefs has been added as an attribute for string,
  float, integer and their *Arrays
2.      some elements and attributes have been annotated as
 belonging to a subset "CoreCML" for simple small molecules
3.      multiple dictRef on molecule removed
4.      delimiter attribute added to floatArray, integerArray, floatMatrix
5.      generic PE's created for many attributes for ease of maintenance
  no new attributes created
6.      dictRef added to a very small number of elements - this is now
  almost universal
-->

<!-- elements and attributes fall into 2 categories:
 coreCML - a subset of CML for easy implementation for small molecules
 fullCML - the full DTD (includes coreCML)
-->
<!-- % fullCML can be overridden
by prepending the statement:
<!ENTITY % fullCML "IGNORE">
at this stage (or transmitting it in from the parser controls if
implemented) -->

<!ENTITY % coreCML      "INCLUDE">
<!ENTITY % fullCML      "INCLUDE">

<!-- =======================================================-->
<!-- PARAMETER ENTITIES                                     -->
<!-- =======================================================-->

<!-- ======attributes found on almost all elements ==========-->

<!ENTITY %      title           'title          CDATA   #IMPLIED'>
<!ENTITY %      id              'id             CDATA   #IMPLIED'>
<!ENTITY %      convention      'convention     CDATA   "CML"'>
<!ENTITY %      dictRef         'dictRef        CDATA   #IMPLIED'>

<!-- a very common combination (on most elements) -->
<!ENTITY %      tit_id_conv     '%title; %id; %convention;'>
<!ENTITY %      tit_id_conv_dict        '%tit_id_conv; %dictRef;'>

<!-- ======linking information ==============================-->

<!ENTITY %      simpleLink      'href           CDATA   #REQUIRED'>

<!-- ======quantifiers and constraints on some primitives ===-->

<!ENTITY %      count           'count          CDATA   "1"'>
<![ %fullCML; [
<!ENTITY %      size            'size           CDATA   #IMPLIED'>
<!ENTITY %      rows            'rows           CDATA   #REQUIRED'>
<!ENTITY %      columns         'columns        CDATA   #REQUIRED'>
]]>
<!ENTITY %      size            ''>
<!ENTITY %      rows            ''>
<!ENTITY %      columns         ''>

<!-- ====== delimiter in Array elements ===-->
<!ENTITY %      delimiter       'delimiter      CDATA   #IMPLIED'>

<!-- ======constraints on some numeric data primitives    ===-->

<!ENTITY %      units           'units          CDATA   #IMPLIED'>

<![%fullCML;[
<!ENTITY %      min             'min            CDATA   #IMPLIED'>
<!ENTITY %      max             'max            CDATA   #IMPLIED'>
<!ENTITY %      angleUnits      'units  (degrees | radians) "degrees"'>
<!ENTITY %      unitsRef        'unitsRef       CDATA           #IMPLIED'>
]]>
<!ENTITY %      min             ''>
<!ENTITY %      max             ''>
<!ENTITY %      angleUnits      ''>
<!ENTITY %      unitsRef        ''>

<!-- for CoreCML degrees are mandatory -->
<!ENTITY %      angleUnits      'units          CDATA   #FIXED "degrees"'>

<!--  values which may be useful in min and max attributes  -->
<!ENTITY %      integer.zero                    '0'>
<!ENTITY %      integer.max                     '2147483647'>
<!ENTITY %      integer.min                     '-2147483648'>
<!ENTITY %      float.zero                      '0.0'>
<!ENTITY %      float.max                       '8.98846567431158E307'>
<!ENTITY %      float.min                       '4.9E-324'>

<!-- ======= builtin values for any element ================-->
<!ENTITY %      builtinId       'id'>

<!-- ======= builtin values for atoms ======================-->
<!ENTITY %      elementType     'elementType'>

<![%fullCML;[
<!ENTITY %      atomId          ' | atomId '>
]]>
<!ENTITY %      atomId          ''>

<!ENTITY %      x2              'x2'>
<!ENTITY %      y2              'y2'>
<!ENTITY %      x3              'x3'>
<!ENTITY %      y3              'y3'>
<!ENTITY %      z3              'z3'>
<!ENTITY %      xy2             'xy2'>
<!ENTITY %      xyz3            'xyz3'>
<!ENTITY %      xFract          'xFract'>
<!ENTITY %      yFract          'yFract'>
<!ENTITY %      zFract          'zFract'>
<!ENTITY %      xyzFract        'xyzFract'>
<!ENTITY %      occupancy       'occupancy'>
<!ENTITY %      isotope         'isotope'>
<!ENTITY %      formalCharge    'formalCharge'>
<!ENTITY %      nonHydrogenCount        'nonHydrogenCount'>
<!ENTITY %      hydrogenCount   'hydrogenCount'>
<!ENTITY %      atomParity      'atomParity'>

<![%fullCML;[
<!ENTITY %      residueType     ' | residueType'>
<!ENTITY %      residueId       ' | residueId'>
]]>
<!ENTITY %      residueType     ''>
<!ENTITY %      residueId       ''>

<!ENTITY %      atomStringBuiltin       '
    %elementType;  %atomId;
    %residueType;  %residueId;
    '
>
<!ENTITY %      atomFloatBuiltin        '
    %x2; | %y2; |
    %x3; | %y3; |  %z3; |
    %xFract; | %yFract; |  %zFract; |
    %occupancy; | %isotope; |
    %formalCharge; | %hydrogenCount; | %nonHydrogenCount; |
    %atomParity;
    '
>
<!ENTITY %      atomIntegerBuiltin      '
    %isotope; |
    %formalCharge; | %hydrogenCount; | %nonHydrogenCount; |
    %atomParity;
    '
>
<!ENTITY %      atomCoordinate2Builtin  '
    %xy2;
    '
>
<!ENTITY %      atomCoordinate3Builtin  '
    %xyz3; | %xyzFract;
    '
>
<!-- ======= builtin values for bonds ======================-->
<!ENTITY %      atomRef         'atomRef'>
<!ENTITY %      builtinAtomRefs 'atomRefs'>
<!ENTITY %      length          'length'>
<!ENTITY %      order           'order'>
<!ENTITY %      stereo          'stereo'>
<!ENTITY %      atomRefs        'atomRefs       CDATA   #IMPLIED'>

<!ENTITY %      bondStringBuiltin       '
    %atomRef; | %builtinAtomRefs; |
    %order; |
    %stereo;
    '
>
<!ENTITY %      bondFloatBuiltin        '
    %length;
    '
>
<!ENTITY %      bondIntegerBuiltin      ''
>
<!-- ======= builtin values for crystal ====================-->

<!ENTITY %      acell                   'acell'>
<!ENTITY %      bcell                   'bcell'>
<!ENTITY %      ccell                   'ccell'>
<!ENTITY %      alpha                   'alpha'>
<!ENTITY %      beta                    'beta'>
<!ENTITY %      gamma                   'gamma'>
<!ENTITY %      z                       'z'>
<!ENTITY %      spacegroup              'spacegroup'>

<!ENTITY %      crystalStringBuiltin    '
    %spacegroup;
    '
>
<!ENTITY %      crystalFloatBuiltin     '
    %acell; | %bcell; | %ccell; |
    %alpha; | %beta; | %gamma; |
    %z;
    '
>
<!ENTITY %      crystalIntegerBuiltin   '
    %z;
    '
>
<!-- =======================================================-->
<!ENTITY %      stringBuiltin   '
    builtin (
    %builtinId; |
    %atomStringBuiltin; |
    %bondStringBuiltin; |
    %crystalStringBuiltin;
    )   #IMPLIED        '
>
<!ENTITY %      floatBuiltin    '
    builtin (
    %atomFloatBuiltin; |
    %bondFloatBuiltin; |
    %crystalFloatBuiltin;
    )   #IMPLIED        '
>
<!ENTITY %      integerBuiltin  '
    builtin (
    %atomIntegerBuiltin; |
    %crystalIntegerBuiltin;
    )   #IMPLIED        '
>
<!ENTITY %      coordinate2Builtin      '
    builtin (
    %atomCoordinate2Builtin;
    )   #IMPLIED        '
>
<!ENTITY %      coordinate3Builtin      '
    builtin (
    %atomCoordinate3Builtin;
    )   #IMPLIED        '
>

<!-- =======================================================-->
<!-- ELEMENTS for widely used data primitives               -->
<!-- =======================================================-->

<!-- CML-DTD V1.01 addition
 certain children of atom or bond may refer to atoms (particularly
 builtin="atomParity" and builtin="stereo"). For these
 we need the attribute 'atomRefs'
-->
<!ENTITY %      scalar.content          '(#PCDATA)'>
<!ENTITY %      array.content           '(#PCDATA)'>
<!ENTITY %      matrix.content          '(#PCDATA)'>
<!ENTITY %      angle.content           '(#PCDATA)'>
<!ENTITY %      coordinate.content      '(#PCDATA)'>

<!ENTITY %      array.atts
   '%size;
   %delimiter;
'>

<!ELEMENT       string          %scalar.content;>
<!ATTLIST       string
                 %tit_id_conv_dict;
   %stringBuiltin;
   %atomRefs;
>
<!-- link is for implementing XLink - only used in fullCML -->
<![ %fullCML; [
<!ELEMENT       link            %scalar.content;>
<!ATTLIST       link
                 %tit_id_conv;
   %simpleLink;
>
]]>

<!ELEMENT       float           %scalar.content;>
<!ATTLIST       float
                 %tit_id_conv_dict;
   %floatBuiltin;
   %min;
   %max;
   %units;
   %unitsRef;
   %atomRefs;
>
<!ELEMENT       integer         %scalar.content;>
<!ATTLIST       integer
                 %tit_id_conv_dict;
   %integerBuiltin;
   %min;
   %max;
   %units;
   %unitsRef;
   %atomRefs;
>
<!ELEMENT       stringArray             %array.content;>
<!ATTLIST       stringArray
                 %tit_id_conv_dict;
   %stringBuiltin;
   %array.atts;
   %min;
   %max;
>
<!ELEMENT       floatArray              %array.content;>
<!ATTLIST       floatArray
                 %tit_id_conv_dict;
   %floatBuiltin;
   %array.atts;
   %units;
   %unitsRef;
   %min;
   %max;
>
<!ELEMENT       integerArray            %array.content;>
<!ATTLIST       integerArray
                 %tit_id_conv_dict;
   %integerBuiltin;
   %array.atts;
   %min;
   %max;
   %units;
   %unitsRef;
>
<!ELEMENT       floatMatrix             %matrix.content;>
<!ATTLIST       floatMatrix
                 %tit_id_conv_dict;
   %rows;
   %columns;
   %min;
   %max;
   %units;
   %unitsRef;
   %delimiter;
>

<!ELEMENT       coordinate2             %coordinate.content;>
<!ATTLIST       coordinate2
                 %tit_id_conv_dict;
   %coordinate2Builtin;
   %unitsRef;
>

<!ELEMENT       coordinate3             %coordinate.content;>
<!ATTLIST       coordinate3
                 %tit_id_conv_dict;
   %coordinate3Builtin;
   %unitsRef;
>
<!ELEMENT       angle                   %angle.content;>
<!ATTLIST       angle
                 %tit_id_conv_dict;
   %atomRefs;
   %angleUnits;
   %min;
   %max;
>

<!ELEMENT       torsion                 %angle.content;>
<!ATTLIST       torsion
                 %tit_id_conv_dict;
   %atomRefs;
   %angleUnits;
   %min;
   %max;
>

<!ELEMENT       list                    ANY>
<!ATTLIST       list
                 %tit_id_conv_dict;
>

<!-- =======================================================-->
<!-- ELEMENTS for chemical and crystallographic concepts    -->
<!-- =======================================================-->
<!-- NOTE
 for elements which have element-specific values for the
 builtin attribute, those values are already listed as
 entities
-->
<!-- =======================================================-->
<![%fullCML;[
<!ENTITY %      molecule.content        'ANY'>
]]>
<!ENTITY %      molecule.content        '(atomArray, bondArray)'>

<!ELEMENT       molecule                %molecule.content;>
<!ATTLIST       molecule
                 %tit_id_conv_dict;
   %count;
>

<!-- ========================================================-->
<!ELEMENT       formula         ANY>
<!ATTLIST       formula
                 %tit_id_conv_dict;
   %count;
>

<!-- ========================================================-->
<![%fullCML;[
<!ENTITY %      atom.content            'ANY'>
]]>
<!ENTITY %      atom.content            '(string | float | integer)*'>
<!ELEMENT       atom                    %atom.content;>
<!ATTLIST       atom
                 %tit_id_conv_dict;
   %count;
>

<!-- .......................................................-->
<![%fullCML;[
<!ENTITY %      atomArray.content       'ANY'>
]]>
<!ENTITY %      atomArray.content       '
   (atom+ | (stringArray | floatArray | integerArray)*)
    '
>
<!ELEMENT       atomArray               %atomArray.content;>
<!ATTLIST       atomArray
                 %tit_id_conv;
>

<!-- ========================================================-->
<![%fullCML;[
<!ENTITY %      bond.content            'ANY'>
]]>
<!ENTITY %      bond.content            '(string | float | integer)*'>
<!ELEMENT       bond                    %bond.content;>
<!ATTLIST       bond
                 %tit_id_conv_dict;
   %atomRefs;
>

<!-- ========================================================-->
<![%fullCML;[
<!ENTITY %      bondArray.content       'ANY'>
]]>
<!ENTITY %      bondArray.content       '
   (bond+ | (stringArray | floatArray | integerArray)*)
    '
>
<!ELEMENT       bondArray               %bondArray.content;>
<!ATTLIST       bondArray
                 %tit_id_conv;
>
<!-- ========================================================-->
<![ %fullCML; [
<!ELEMENT       electron                ANY>
<!ATTLIST       electron
                 %tit_id_conv_dict;
   %count;
>
]]>
<!-- ========================================================-->
<![ %fullCML; [
<!ELEMENT       reaction                ANY>
<!ATTLIST       reaction
                 %tit_id_conv_dict;
>
]]>

<!-- ======================================================= -->

<![%fullCML;[
<!ENTITY %      crystal.content         'ANY'>
]]>
<!ENTITY %      crystal.content         '(string | float | integer)*'>
<!ELEMENT       crystal                 %crystal.content;>
<!ATTLIST       crystal
                 %tit_id_conv_dict;
>

<!-- ======================================================= -->
<![ %fullCML; [
<!ELEMENT       sequence                ANY>
<!ATTLIST       sequence
                 %tit_id_conv_dict;
>
]]>

<!-- ======================================================= -->
<![ %fullCML; [
<!ELEMENT       feature         ANY>
<!ATTLIST       feature
                 %tit_id_conv_dict;
>
]]>