relaton-nist 0.3.6 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.github/workflows/macos.yml +27 -0
- data/.github/workflows/ubuntu.yml +27 -0
- data/.github/workflows/windows.yml +30 -0
- data/Gemfile.lock +9 -5
- data/grammars/basicdoc.rng +1029 -0
- data/grammars/biblio.rng +1142 -0
- data/grammars/isodoc.rng +514 -0
- data/grammars/isostandard.rng +857 -0
- data/grammars/nist.rng +227 -0
- data/grammars/reqt.rng +165 -0
- data/lib/relaton_nist.rb +9 -0
- data/lib/relaton_nist/hit_collection.rb +3 -1
- data/lib/relaton_nist/nist_bibliographic_item.rb +1 -1
- data/lib/relaton_nist/nist_bibliography.rb +2 -0
- data/lib/relaton_nist/processor.rb +7 -1
- data/lib/relaton_nist/scrapper.rb +2 -2
- data/lib/relaton_nist/version.rb +1 -1
- data/relaton_nist.gemspec +2 -1
- metadata +28 -9
- data/.travis.yml +0 -18
- data/appveyor.yml +0 -37
- data/lib/relaton_nist/data/pubs-export.zip +0 -0
data/grammars/isodoc.rng
ADDED
@@ -0,0 +1,514 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<!--
|
3
|
+
instantiations of this grammar may replace leaf strings
|
4
|
+
with more elaborated types; e.g. title (text) replaced with
|
5
|
+
title-main, title-intro, title-part; type replaced with
|
6
|
+
enum.
|
7
|
+
|
8
|
+
some renaming at leaf nodes is permissible
|
9
|
+
|
10
|
+
obligations can change both from optional to mandatory,
|
11
|
+
and from mandatory to optional; optional elements may
|
12
|
+
be omitted; freely positioned alternatives may be replaced
|
13
|
+
with strict ordering
|
14
|
+
|
15
|
+
DO NOT introduce a namespace here. We do not want a distinct namespace
|
16
|
+
for these elements, and a distinct namespace for any grammar inheriting
|
17
|
+
these elements; we just want one namespace for any child grammars
|
18
|
+
of this.
|
19
|
+
-->
|
20
|
+
<grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
21
|
+
<include href="reqt.rng"/>
|
22
|
+
<!-- include "biblio.rnc" { } -->
|
23
|
+
<include href="basicdoc.rng">
|
24
|
+
<start>
|
25
|
+
<ref name="standard-document"/>
|
26
|
+
</start>
|
27
|
+
<define name="BibDataExtensionType">
|
28
|
+
<ref name="doctype"/>
|
29
|
+
<zeroOrMore>
|
30
|
+
<ref name="structuredidentifier"/>
|
31
|
+
</zeroOrMore>
|
32
|
+
</define>
|
33
|
+
<define name="TitleType">
|
34
|
+
<text/>
|
35
|
+
</define>
|
36
|
+
<define name="sections">
|
37
|
+
<element name="sections">
|
38
|
+
<oneOrMore>
|
39
|
+
<choice>
|
40
|
+
<ref name="clause"/>
|
41
|
+
<ref name="terms"/>
|
42
|
+
<ref name="definitions"/>
|
43
|
+
</choice>
|
44
|
+
</oneOrMore>
|
45
|
+
</element>
|
46
|
+
</define>
|
47
|
+
<define name="references">
|
48
|
+
<element name="references">
|
49
|
+
<optional>
|
50
|
+
<attribute name="id">
|
51
|
+
<data type="ID"/>
|
52
|
+
</attribute>
|
53
|
+
</optional>
|
54
|
+
<optional>
|
55
|
+
<ref name="section-title"/>
|
56
|
+
</optional>
|
57
|
+
<zeroOrMore>
|
58
|
+
<ref name="BasicBlock"/>
|
59
|
+
</zeroOrMore>
|
60
|
+
<zeroOrMore>
|
61
|
+
<ref name="bibitem"/>
|
62
|
+
<zeroOrMore>
|
63
|
+
<ref name="note"/>
|
64
|
+
</zeroOrMore>
|
65
|
+
</zeroOrMore>
|
66
|
+
</element>
|
67
|
+
</define>
|
68
|
+
</include>
|
69
|
+
<define name="standard-document">
|
70
|
+
<element name="standard-document">
|
71
|
+
<ref name="bibdata"/>
|
72
|
+
<optional>
|
73
|
+
<ref name="boilerplate"/>
|
74
|
+
</optional>
|
75
|
+
<optional>
|
76
|
+
<ref name="preface"/>
|
77
|
+
</optional>
|
78
|
+
<ref name="sections"/>
|
79
|
+
<zeroOrMore>
|
80
|
+
<ref name="annex"/>
|
81
|
+
</zeroOrMore>
|
82
|
+
<zeroOrMore>
|
83
|
+
<ref name="references"/>
|
84
|
+
</zeroOrMore>
|
85
|
+
</element>
|
86
|
+
</define>
|
87
|
+
<define name="preface">
|
88
|
+
<element name="preface">
|
89
|
+
<oneOrMore>
|
90
|
+
<choice>
|
91
|
+
<ref name="content"/>
|
92
|
+
<ref name="abstract"/>
|
93
|
+
<ref name="foreword"/>
|
94
|
+
<ref name="introduction"/>
|
95
|
+
<ref name="acknowledgements"/>
|
96
|
+
</choice>
|
97
|
+
</oneOrMore>
|
98
|
+
</element>
|
99
|
+
</define>
|
100
|
+
<define name="foreword">
|
101
|
+
<element name="foreword">
|
102
|
+
<ref name="Content-Section"/>
|
103
|
+
</element>
|
104
|
+
</define>
|
105
|
+
<define name="introduction">
|
106
|
+
<element name="introduction">
|
107
|
+
<ref name="Content-Section"/>
|
108
|
+
</element>
|
109
|
+
</define>
|
110
|
+
<define name="boilerplate">
|
111
|
+
<element name="boilerplate">
|
112
|
+
<optional>
|
113
|
+
<ref name="copyright-statement"/>
|
114
|
+
</optional>
|
115
|
+
<optional>
|
116
|
+
<ref name="license-statement"/>
|
117
|
+
</optional>
|
118
|
+
<optional>
|
119
|
+
<ref name="legal-statement"/>
|
120
|
+
</optional>
|
121
|
+
<optional>
|
122
|
+
<ref name="feedback-statement"/>
|
123
|
+
</optional>
|
124
|
+
</element>
|
125
|
+
</define>
|
126
|
+
<define name="copyright-statement">
|
127
|
+
<element name="copyright-statement">
|
128
|
+
<ref name="Content-Section"/>
|
129
|
+
</element>
|
130
|
+
</define>
|
131
|
+
<define name="license-statement">
|
132
|
+
<element name="license-statement">
|
133
|
+
<ref name="Content-Section"/>
|
134
|
+
</element>
|
135
|
+
</define>
|
136
|
+
<define name="legal-statement">
|
137
|
+
<element name="legal-statement">
|
138
|
+
<ref name="Content-Section"/>
|
139
|
+
</element>
|
140
|
+
</define>
|
141
|
+
<define name="feedback-statement">
|
142
|
+
<element name="feedback-statement">
|
143
|
+
<ref name="Content-Section"/>
|
144
|
+
</element>
|
145
|
+
</define>
|
146
|
+
<define name="definitions">
|
147
|
+
<element name="definitions">
|
148
|
+
<optional>
|
149
|
+
<attribute name="id">
|
150
|
+
<data type="ID"/>
|
151
|
+
</attribute>
|
152
|
+
</optional>
|
153
|
+
<optional>
|
154
|
+
<attribute name="language"/>
|
155
|
+
</optional>
|
156
|
+
<optional>
|
157
|
+
<attribute name="script"/>
|
158
|
+
</optional>
|
159
|
+
<optional>
|
160
|
+
<ref name="section-title"/>
|
161
|
+
</optional>
|
162
|
+
<oneOrMore>
|
163
|
+
<zeroOrMore>
|
164
|
+
<ref name="BasicBlock"/>
|
165
|
+
</zeroOrMore>
|
166
|
+
<ref name="dl"/>
|
167
|
+
</oneOrMore>
|
168
|
+
</element>
|
169
|
+
</define>
|
170
|
+
<define name="content">
|
171
|
+
<element name="clause">
|
172
|
+
<ref name="Content-Section"/>
|
173
|
+
</element>
|
174
|
+
</define>
|
175
|
+
<define name="abstract">
|
176
|
+
<element name="abstract">
|
177
|
+
<ref name="Content-Section"/>
|
178
|
+
</element>
|
179
|
+
</define>
|
180
|
+
<define name="acknowledgements">
|
181
|
+
<element name="acknowledgements">
|
182
|
+
<ref name="Content-Section"/>
|
183
|
+
</element>
|
184
|
+
</define>
|
185
|
+
<define name="content-subsection">
|
186
|
+
<element name="clause">
|
187
|
+
<optional>
|
188
|
+
<attribute name="type"/>
|
189
|
+
</optional>
|
190
|
+
<ref name="Content-Section"/>
|
191
|
+
</element>
|
192
|
+
</define>
|
193
|
+
<define name="Content-Section">
|
194
|
+
<optional>
|
195
|
+
<attribute name="id">
|
196
|
+
<data type="ID"/>
|
197
|
+
</attribute>
|
198
|
+
</optional>
|
199
|
+
<optional>
|
200
|
+
<attribute name="language"/>
|
201
|
+
</optional>
|
202
|
+
<optional>
|
203
|
+
<attribute name="script"/>
|
204
|
+
</optional>
|
205
|
+
<optional>
|
206
|
+
<ref name="section-title"/>
|
207
|
+
</optional>
|
208
|
+
<choice>
|
209
|
+
<group>
|
210
|
+
<optional>
|
211
|
+
<ref name="BasicBlock"/>
|
212
|
+
</optional>
|
213
|
+
<zeroOrMore>
|
214
|
+
<ref name="note"/>
|
215
|
+
</zeroOrMore>
|
216
|
+
</group>
|
217
|
+
<oneOrMore>
|
218
|
+
<ref name="content-subsection"/>
|
219
|
+
</oneOrMore>
|
220
|
+
</choice>
|
221
|
+
</define>
|
222
|
+
<define name="clause">
|
223
|
+
<element name="clause">
|
224
|
+
<optional>
|
225
|
+
<attribute name="type"/>
|
226
|
+
</optional>
|
227
|
+
<ref name="Clause-Section"/>
|
228
|
+
</element>
|
229
|
+
</define>
|
230
|
+
<define name="Clause-Section">
|
231
|
+
<optional>
|
232
|
+
<attribute name="id">
|
233
|
+
<data type="ID"/>
|
234
|
+
</attribute>
|
235
|
+
</optional>
|
236
|
+
<optional>
|
237
|
+
<attribute name="language"/>
|
238
|
+
</optional>
|
239
|
+
<optional>
|
240
|
+
<attribute name="script"/>
|
241
|
+
</optional>
|
242
|
+
<optional>
|
243
|
+
<ref name="section-title"/>
|
244
|
+
</optional>
|
245
|
+
<choice>
|
246
|
+
<group>
|
247
|
+
<optional>
|
248
|
+
<ref name="BasicBlock"/>
|
249
|
+
</optional>
|
250
|
+
<zeroOrMore>
|
251
|
+
<ref name="note"/>
|
252
|
+
</zeroOrMore>
|
253
|
+
</group>
|
254
|
+
<oneOrMore>
|
255
|
+
<choice>
|
256
|
+
<ref name="clause-subsection"/>
|
257
|
+
<ref name="terms"/>
|
258
|
+
<ref name="definitions"/>
|
259
|
+
</choice>
|
260
|
+
</oneOrMore>
|
261
|
+
</choice>
|
262
|
+
</define>
|
263
|
+
<define name="clause-subsection">
|
264
|
+
<element name="clause">
|
265
|
+
<ref name="Clause-Section"/>
|
266
|
+
</element>
|
267
|
+
</define>
|
268
|
+
<define name="annex">
|
269
|
+
<element name="annex">
|
270
|
+
<optional>
|
271
|
+
<attribute name="id">
|
272
|
+
<data type="ID"/>
|
273
|
+
</attribute>
|
274
|
+
</optional>
|
275
|
+
<optional>
|
276
|
+
<attribute name="language"/>
|
277
|
+
</optional>
|
278
|
+
<optional>
|
279
|
+
<attribute name="script"/>
|
280
|
+
</optional>
|
281
|
+
<attribute name="obligation">
|
282
|
+
<choice>
|
283
|
+
<value>normative</value>
|
284
|
+
<value>informative</value>
|
285
|
+
</choice>
|
286
|
+
</attribute>
|
287
|
+
<optional>
|
288
|
+
<ref name="section-title"/>
|
289
|
+
</optional>
|
290
|
+
<choice>
|
291
|
+
<group>
|
292
|
+
<optional>
|
293
|
+
<ref name="BasicBlock"/>
|
294
|
+
</optional>
|
295
|
+
<zeroOrMore>
|
296
|
+
<ref name="note"/>
|
297
|
+
</zeroOrMore>
|
298
|
+
</group>
|
299
|
+
<oneOrMore>
|
300
|
+
<ref name="clause-subsection"/>
|
301
|
+
</oneOrMore>
|
302
|
+
</choice>
|
303
|
+
</element>
|
304
|
+
</define>
|
305
|
+
<define name="terms">
|
306
|
+
<element name="terms">
|
307
|
+
<optional>
|
308
|
+
<attribute name="id">
|
309
|
+
<data type="ID"/>
|
310
|
+
</attribute>
|
311
|
+
</optional>
|
312
|
+
<optional>
|
313
|
+
<attribute name="language"/>
|
314
|
+
</optional>
|
315
|
+
<optional>
|
316
|
+
<attribute name="script"/>
|
317
|
+
</optional>
|
318
|
+
<zeroOrMore>
|
319
|
+
<ref name="BasicBlock"/>
|
320
|
+
</zeroOrMore>
|
321
|
+
<oneOrMore>
|
322
|
+
<ref name="term"/>
|
323
|
+
</oneOrMore>
|
324
|
+
</element>
|
325
|
+
</define>
|
326
|
+
<define name="term">
|
327
|
+
<element name="term">
|
328
|
+
<optional>
|
329
|
+
<attribute name="id">
|
330
|
+
<data type="ID"/>
|
331
|
+
</attribute>
|
332
|
+
</optional>
|
333
|
+
<oneOrMore>
|
334
|
+
<ref name="preferred"/>
|
335
|
+
</oneOrMore>
|
336
|
+
<zeroOrMore>
|
337
|
+
<ref name="admitted"/>
|
338
|
+
</zeroOrMore>
|
339
|
+
<zeroOrMore>
|
340
|
+
<ref name="related"/>
|
341
|
+
</zeroOrMore>
|
342
|
+
<zeroOrMore>
|
343
|
+
<ref name="deprecates"/>
|
344
|
+
</zeroOrMore>
|
345
|
+
<optional>
|
346
|
+
<ref name="termdomain"/>
|
347
|
+
</optional>
|
348
|
+
<zeroOrMore>
|
349
|
+
<ref name="termgrammar"/>
|
350
|
+
</zeroOrMore>
|
351
|
+
<ref name="definition"/>
|
352
|
+
<zeroOrMore>
|
353
|
+
<ref name="termnote"/>
|
354
|
+
</zeroOrMore>
|
355
|
+
<zeroOrMore>
|
356
|
+
<ref name="termexample"/>
|
357
|
+
</zeroOrMore>
|
358
|
+
<zeroOrMore>
|
359
|
+
<ref name="termsource"/>
|
360
|
+
</zeroOrMore>
|
361
|
+
</element>
|
362
|
+
</define>
|
363
|
+
<define name="preferred">
|
364
|
+
<element name="preferred">
|
365
|
+
<oneOrMore>
|
366
|
+
<ref name="TextElement"/>
|
367
|
+
</oneOrMore>
|
368
|
+
</element>
|
369
|
+
</define>
|
370
|
+
<define name="admitted">
|
371
|
+
<element name="admitted">
|
372
|
+
<oneOrMore>
|
373
|
+
<ref name="TextElement"/>
|
374
|
+
</oneOrMore>
|
375
|
+
</element>
|
376
|
+
</define>
|
377
|
+
<define name="related">
|
378
|
+
<element name="related">
|
379
|
+
<optional>
|
380
|
+
<attribute name="type">
|
381
|
+
<choice>
|
382
|
+
<value>compare</value>
|
383
|
+
<value>contrast</value>
|
384
|
+
<value>see</value>
|
385
|
+
</choice>
|
386
|
+
</attribute>
|
387
|
+
</optional>
|
388
|
+
<oneOrMore>
|
389
|
+
<ref name="TextElement"/>
|
390
|
+
</oneOrMore>
|
391
|
+
</element>
|
392
|
+
</define>
|
393
|
+
<define name="deprecates">
|
394
|
+
<element name="deprecates">
|
395
|
+
<oneOrMore>
|
396
|
+
<ref name="TextElement"/>
|
397
|
+
</oneOrMore>
|
398
|
+
</element>
|
399
|
+
</define>
|
400
|
+
<define name="termdomain">
|
401
|
+
<element name="domain">
|
402
|
+
<oneOrMore>
|
403
|
+
<ref name="TextElement"/>
|
404
|
+
</oneOrMore>
|
405
|
+
</element>
|
406
|
+
</define>
|
407
|
+
<define name="termgrammar">
|
408
|
+
<element name="grammar">
|
409
|
+
<oneOrMore>
|
410
|
+
<ref name="TextElement"/>
|
411
|
+
</oneOrMore>
|
412
|
+
</element>
|
413
|
+
</define>
|
414
|
+
<define name="definition">
|
415
|
+
<element name="definition">
|
416
|
+
<ref name="paragraph"/>
|
417
|
+
</element>
|
418
|
+
</define>
|
419
|
+
<define name="termnote">
|
420
|
+
<element name="termnote">
|
421
|
+
<attribute name="id">
|
422
|
+
<data type="ID"/>
|
423
|
+
</attribute>
|
424
|
+
<ref name="paragraph"/>
|
425
|
+
</element>
|
426
|
+
</define>
|
427
|
+
<define name="termexample">
|
428
|
+
<element name="termexample">
|
429
|
+
<attribute name="id">
|
430
|
+
<data type="ID"/>
|
431
|
+
</attribute>
|
432
|
+
<ref name="paragraph"/>
|
433
|
+
</element>
|
434
|
+
</define>
|
435
|
+
<define name="termsource">
|
436
|
+
<element name="termsource">
|
437
|
+
<attribute name="status">
|
438
|
+
<choice>
|
439
|
+
<value>identical</value>
|
440
|
+
<value>modified</value>
|
441
|
+
</choice>
|
442
|
+
</attribute>
|
443
|
+
<ref name="origin"/>
|
444
|
+
<optional>
|
445
|
+
<ref name="modification"/>
|
446
|
+
</optional>
|
447
|
+
</element>
|
448
|
+
</define>
|
449
|
+
<define name="origin">
|
450
|
+
<element name="origin">
|
451
|
+
<ref name="erefType"/>
|
452
|
+
</element>
|
453
|
+
</define>
|
454
|
+
<define name="modification">
|
455
|
+
<element name="modification">
|
456
|
+
<ref name="paragraph"/>
|
457
|
+
</element>
|
458
|
+
</define>
|
459
|
+
<define name="structuredidentifier">
|
460
|
+
<element name="structuredidentifier">
|
461
|
+
<optional>
|
462
|
+
<attribute name="type"/>
|
463
|
+
</optional>
|
464
|
+
<oneOrMore>
|
465
|
+
<element name="agency">
|
466
|
+
<text/>
|
467
|
+
</element>
|
468
|
+
</oneOrMore>
|
469
|
+
<optional>
|
470
|
+
<element name="class">
|
471
|
+
<text/>
|
472
|
+
</element>
|
473
|
+
</optional>
|
474
|
+
<element name="docnumber">
|
475
|
+
<text/>
|
476
|
+
</element>
|
477
|
+
<optional>
|
478
|
+
<element name="partnumber">
|
479
|
+
<text/>
|
480
|
+
</element>
|
481
|
+
</optional>
|
482
|
+
<optional>
|
483
|
+
<element name="edition">
|
484
|
+
<text/>
|
485
|
+
</element>
|
486
|
+
</optional>
|
487
|
+
<optional>
|
488
|
+
<element name="version">
|
489
|
+
<text/>
|
490
|
+
</element>
|
491
|
+
</optional>
|
492
|
+
<optional>
|
493
|
+
<element name="supplementtype">
|
494
|
+
<text/>
|
495
|
+
</element>
|
496
|
+
</optional>
|
497
|
+
<optional>
|
498
|
+
<element name="supplementnumber">
|
499
|
+
<text/>
|
500
|
+
</element>
|
501
|
+
</optional>
|
502
|
+
<optional>
|
503
|
+
<element name="language">
|
504
|
+
<text/>
|
505
|
+
</element>
|
506
|
+
</optional>
|
507
|
+
<optional>
|
508
|
+
<element name="year">
|
509
|
+
<text/>
|
510
|
+
</element>
|
511
|
+
</optional>
|
512
|
+
</element>
|
513
|
+
</define>
|
514
|
+
</grammar>
|