relaton-nist 1.11.2 → 1.12.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '095a15201f14cd98e0e838767c84345b6c3963fd40a820c380e2d473d6974911'
4
- data.tar.gz: b95ac950a2c35a3f24b788544cc66e064e24abd64e0953e791a343a5a031ac82
3
+ metadata.gz: f66b74deb926d9f67db5770896b1080b16610c3996edb4a404740bd3ce558abe
4
+ data.tar.gz: 6b74fb0c0bb1bf46282496fbf9e91f1a7ca0022eb4466f3be69ed1ca3da09b1c
5
5
  SHA512:
6
- metadata.gz: 49830f72fa98e99c018694f8cface13e108cfffe4de3163870e12d02a6434006fe6d48a40480041a3d2ff1a39cded6243fb0c35f07450c2429107a56890e7cc9
7
- data.tar.gz: 5d482c2805ee879b8728627b495a638b46604f6aecc898b0f75c2e8a114fc5d23d778e297cd59567b6da8375d7d011729fc5df3b39dc4eed9657c329679086ef
6
+ metadata.gz: 97ca67f282f4131fab6f6d9da60e8f1ab350d8e5e762d843066f4236b8d5a53980d261c29559f9c233c2cab5cee44bbc185ab7a6b3feedd559df5d631a94b61c
7
+ data.tar.gz: 6c2a40d739b0b2b9b2ed9587c50ac737b5a3ccb8a7c27c5b1548cab40f3409c08ea62358bb2b90d590b04ac45350e3ba671c0dac7a479399ce38d06ad9519904
@@ -10,27 +10,4 @@ on:
10
10
 
11
11
  jobs:
12
12
  rake:
13
- name: Test on Ruby ${{ matrix.ruby }} ${{ matrix.os }}
14
- runs-on: ${{ matrix.os }}
15
- continue-on-error: ${{ matrix.experimental }}
16
- strategy:
17
- fail-fast: false
18
- matrix:
19
- ruby: [ '3.0', '2.7', '2.6', '2.5' ]
20
- os: [ ubuntu-latest, windows-latest, macos-latest ]
21
- experimental: [ false ]
22
- steps:
23
- - uses: actions/checkout@v2
24
- with:
25
- submodules: true
26
-
27
- # https://github.com/ruby-debug/debase/issues/89#issuecomment-686827382
28
- - if: matrix.os == 'macos-latest' && matrix.ruby == '2.5'
29
- run: echo BUNDLE_BUILD__DEBASE="--with-cflags=\"-Wno-error=implicit-function-declaration\"" >> $GITHUB_ENV
30
-
31
- - uses: ruby/setup-ruby@v1
32
- with:
33
- ruby-version: ${{ matrix.ruby }}
34
- bundler-cache: true
35
-
36
- - run: bundle exec rake
13
+ uses: relaton/support/.github/workflows/rake.yml@master
data/.rubocop.yml CHANGED
@@ -7,6 +7,6 @@ require: rubocop-rails
7
7
  inherit_from:
8
8
  - https://raw.githubusercontent.com/riboseinc/oss-guides/master/ci/rubocop.yml
9
9
  AllCops:
10
- TargetRubyVersion: 2.5
10
+ TargetRubyVersion: 2.6
11
11
  Rails:
12
12
  Enabled: false
data/grammars/biblio.rng CHANGED
@@ -527,7 +527,7 @@
527
527
  </define>
528
528
  <define name="LocalityType">
529
529
  <data type="string">
530
- <param name="pattern">section|clause|part|paragraph|chapter|page|whole|table|annex|figure|note|list|example|volume|issue|time|anchor|locality:[a-zA-Z0-9_]+</param>
530
+ <param name="pattern">section|clause|part|paragraph|chapter|page|title|line|whole|table|annex|figure|note|list|example|volume|issue|time|anchor|locality:[a-zA-Z0-9_]+</param>
531
531
  </data>
532
532
  </define>
533
533
  <define name="referenceFrom">
@@ -614,12 +614,103 @@
614
614
  <optional>
615
615
  <ref name="fetched"/>
616
616
  </optional>
617
- <choice>
618
- <oneOrMore>
619
- <ref name="btitle"/>
620
- </oneOrMore>
617
+ <optional>
621
618
  <ref name="formattedref"/>
622
- </choice>
619
+ </optional>
620
+ <oneOrMore>
621
+ <ref name="btitle"/>
622
+ </oneOrMore>
623
+ <zeroOrMore>
624
+ <ref name="bsource"/>
625
+ </zeroOrMore>
626
+ <oneOrMore>
627
+ <ref name="docidentifier"/>
628
+ </oneOrMore>
629
+ <optional>
630
+ <ref name="docnumber"/>
631
+ </optional>
632
+ <zeroOrMore>
633
+ <ref name="bdate"/>
634
+ </zeroOrMore>
635
+ <zeroOrMore>
636
+ <ref name="contributor"/>
637
+ </zeroOrMore>
638
+ <optional>
639
+ <ref name="edition"/>
640
+ </optional>
641
+ <zeroOrMore>
642
+ <ref name="version"/>
643
+ </zeroOrMore>
644
+ <zeroOrMore>
645
+ <ref name="biblionote"/>
646
+ </zeroOrMore>
647
+ <zeroOrMore>
648
+ <ref name="language"/>
649
+ </zeroOrMore>
650
+ <zeroOrMore>
651
+ <ref name="script"/>
652
+ </zeroOrMore>
653
+ <zeroOrMore>
654
+ <ref name="bibabstract"/>
655
+ </zeroOrMore>
656
+ <optional>
657
+ <ref name="status"/>
658
+ </optional>
659
+ <zeroOrMore>
660
+ <ref name="copyright"/>
661
+ </zeroOrMore>
662
+ <zeroOrMore>
663
+ <ref name="docrelation"/>
664
+ </zeroOrMore>
665
+ <zeroOrMore>
666
+ <ref name="series"/>
667
+ </zeroOrMore>
668
+ <optional>
669
+ <ref name="medium"/>
670
+ </optional>
671
+ <zeroOrMore>
672
+ <ref name="bplace"/>
673
+ </zeroOrMore>
674
+ <zeroOrMore>
675
+ <ref name="bprice"/>
676
+ </zeroOrMore>
677
+ <zeroOrMore>
678
+ <ref name="extent"/>
679
+ </zeroOrMore>
680
+ <optional>
681
+ <ref name="bibliographic_size"/>
682
+ </optional>
683
+ <zeroOrMore>
684
+ <ref name="accesslocation"/>
685
+ </zeroOrMore>
686
+ <zeroOrMore>
687
+ <ref name="license"/>
688
+ </zeroOrMore>
689
+ <zeroOrMore>
690
+ <ref name="bclassification"/>
691
+ </zeroOrMore>
692
+ <zeroOrMore>
693
+ <ref name="bkeyword"/>
694
+ </zeroOrMore>
695
+ <optional>
696
+ <ref name="validity"/>
697
+ </optional>
698
+ </define>
699
+ <define name="ReducedBibliographicItem">
700
+ <optional>
701
+ <attribute name="type">
702
+ <ref name="BibItemType"/>
703
+ </attribute>
704
+ </optional>
705
+ <optional>
706
+ <ref name="fetched"/>
707
+ </optional>
708
+ <optional>
709
+ <ref name="formattedref"/>
710
+ </optional>
711
+ <zeroOrMore>
712
+ <ref name="btitle"/>
713
+ </zeroOrMore>
623
714
  <zeroOrMore>
624
715
  <ref name="bsource"/>
625
716
  </zeroOrMore>
@@ -638,9 +729,9 @@
638
729
  <optional>
639
730
  <ref name="edition"/>
640
731
  </optional>
641
- <optional>
732
+ <zeroOrMore>
642
733
  <ref name="version"/>
643
- </optional>
734
+ </zeroOrMore>
644
735
  <zeroOrMore>
645
736
  <ref name="biblionote"/>
646
737
  </zeroOrMore>
@@ -833,6 +924,12 @@
833
924
  <data type="boolean"/>
834
925
  </attribute>
835
926
  </optional>
927
+ <optional>
928
+ <attribute name="language"/>
929
+ </optional>
930
+ <optional>
931
+ <attribute name="script"/>
932
+ </optional>
836
933
  <text/>
837
934
  </element>
838
935
  </define>
@@ -851,17 +948,46 @@
851
948
  </define>
852
949
  <define name="bplace">
853
950
  <element name="place">
854
- <optional>
855
- <attribute name="uri">
856
- <data type="anyURI"/>
857
- </attribute>
858
- </optional>
859
- <optional>
860
- <attribute name="region"/>
861
- </optional>
951
+ <choice>
952
+ <text/>
953
+ <group>
954
+ <ref name="bibliocity"/>
955
+ <zeroOrMore>
956
+ <ref name="biblioregion"/>
957
+ </zeroOrMore>
958
+ <zeroOrMore>
959
+ <ref name="bibliocountry"/>
960
+ </zeroOrMore>
961
+ </group>
962
+ </choice>
963
+ </element>
964
+ </define>
965
+ <define name="bibliocity">
966
+ <element name="city">
862
967
  <text/>
863
968
  </element>
864
969
  </define>
970
+ <define name="biblioregion">
971
+ <element name="region">
972
+ <ref name="RegionType"/>
973
+ </element>
974
+ </define>
975
+ <define name="bibliocountry">
976
+ <element name="country">
977
+ <ref name="RegionType"/>
978
+ </element>
979
+ </define>
980
+ <define name="RegionType">
981
+ <optional>
982
+ <attribute name="iso"/>
983
+ </optional>
984
+ <optional>
985
+ <attribute name="recommended">
986
+ <data type="boolean"/>
987
+ </attribute>
988
+ </optional>
989
+ <text/>
990
+ </define>
865
991
  <define name="bprice">
866
992
  <element name="price">
867
993
  <attribute name="currency"/>
@@ -957,36 +1083,34 @@
957
1083
  <ref name="SeriesType"/>
958
1084
  </attribute>
959
1085
  </optional>
960
- <choice>
1086
+ <optional>
961
1087
  <ref name="formattedref"/>
962
- <group>
963
- <ref name="btitle"/>
964
- <optional>
965
- <ref name="bplace"/>
966
- </optional>
967
- <optional>
968
- <ref name="seriesorganization"/>
969
- </optional>
970
- <optional>
971
- <ref name="abbreviation"/>
972
- </optional>
973
- <optional>
974
- <ref name="seriesfrom"/>
975
- </optional>
976
- <optional>
977
- <ref name="seriesto"/>
978
- </optional>
979
- <optional>
980
- <ref name="seriesnumber"/>
981
- </optional>
982
- <optional>
983
- <ref name="seriespartnumber"/>
984
- </optional>
985
- <optional>
986
- <ref name="seriesrun"/>
987
- </optional>
988
- </group>
989
- </choice>
1088
+ </optional>
1089
+ <ref name="btitle"/>
1090
+ <optional>
1091
+ <ref name="bplace"/>
1092
+ </optional>
1093
+ <optional>
1094
+ <ref name="seriesorganization"/>
1095
+ </optional>
1096
+ <optional>
1097
+ <ref name="abbreviation"/>
1098
+ </optional>
1099
+ <optional>
1100
+ <ref name="seriesfrom"/>
1101
+ </optional>
1102
+ <optional>
1103
+ <ref name="seriesto"/>
1104
+ </optional>
1105
+ <optional>
1106
+ <ref name="seriesnumber"/>
1107
+ </optional>
1108
+ <optional>
1109
+ <ref name="seriespartnumber"/>
1110
+ </optional>
1111
+ <optional>
1112
+ <ref name="seriesrun"/>
1113
+ </optional>
990
1114
  </element>
991
1115
  </define>
992
1116
  <define name="SeriesType">
@@ -1145,7 +1269,7 @@
1145
1269
  </element>
1146
1270
  </optional>
1147
1271
  <element name="bibitem">
1148
- <ref name="BibliographicItem"/>
1272
+ <ref name="ReducedBibliographicItem"/>
1149
1273
  </element>
1150
1274
  <choice>
1151
1275
  <zeroOrMore>
@@ -1170,9 +1294,9 @@
1170
1294
  <optional>
1171
1295
  <ref name="revision-date"/>
1172
1296
  </optional>
1173
- <zeroOrMore>
1297
+ <optional>
1174
1298
  <ref name="draft"/>
1175
- </zeroOrMore>
1299
+ </optional>
1176
1300
  </element>
1177
1301
  </define>
1178
1302
  <define name="vedition">
data/grammars/isodoc.rng CHANGED
@@ -32,6 +32,43 @@
32
32
  <ref name="DocumentType"/>
33
33
  </element>
34
34
  </define>
35
+ <define name="admonition">
36
+ <element name="admonition">
37
+ <attribute name="type">
38
+ <ref name="AdmonitionType"/>
39
+ </attribute>
40
+ <optional>
41
+ <attribute name="class"/>
42
+ </optional>
43
+ <attribute name="id">
44
+ <data type="ID"/>
45
+ </attribute>
46
+ <optional>
47
+ <attribute name="uri">
48
+ <data type="anyURI"/>
49
+ </attribute>
50
+ </optional>
51
+ <optional>
52
+ <attribute name="coverpage">
53
+ <data type="boolean"/>
54
+ </attribute>
55
+ </optional>
56
+ <optional>
57
+ <attribute name="notag">
58
+ <data type="boolean"/>
59
+ </attribute>
60
+ </optional>
61
+ <optional>
62
+ <ref name="tname"/>
63
+ </optional>
64
+ <zeroOrMore>
65
+ <ref name="paragraph-with-footnote"/>
66
+ </zeroOrMore>
67
+ <zeroOrMore>
68
+ <ref name="note"/>
69
+ </zeroOrMore>
70
+ </element>
71
+ </define>
35
72
  <define name="index">
36
73
  <element name="index">
37
74
  <optional>
@@ -79,6 +116,11 @@
79
116
  <data type="boolean"/>
80
117
  </attribute>
81
118
  </optional>
119
+ <optional>
120
+ <attribute name="suppress_identifier">
121
+ <data type="boolean"/>
122
+ </attribute>
123
+ </optional>
82
124
  <ref name="BibliographicItem"/>
83
125
  </element>
84
126
  </define>
@@ -245,6 +287,9 @@
245
287
  <ref name="MultilingualRenderingType"/>
246
288
  </attribute>
247
289
  </optional>
290
+ <optional>
291
+ <ref name="tname"/>
292
+ </optional>
248
293
  <oneOrMore>
249
294
  <ref name="ul_li"/>
250
295
  </oneOrMore>
@@ -287,6 +332,9 @@
287
332
  </choice>
288
333
  </attribute>
289
334
  </optional>
335
+ <optional>
336
+ <ref name="tname"/>
337
+ </optional>
290
338
  <oneOrMore>
291
339
  <ref name="li"/>
292
340
  </oneOrMore>
@@ -323,6 +371,9 @@
323
371
  <ref name="MultilingualRenderingType"/>
324
372
  </attribute>
325
373
  </optional>
374
+ <optional>
375
+ <ref name="tname"/>
376
+ </optional>
326
377
  <oneOrMore>
327
378
  <ref name="dt"/>
328
379
  <ref name="dd"/>
@@ -657,6 +708,9 @@
657
708
  <optional>
658
709
  <attribute name="tag"/>
659
710
  </optional>
711
+ <optional>
712
+ <attribute name="type"/>
713
+ </optional>
660
714
  <optional>
661
715
  <attribute name="multilingual-rendering">
662
716
  <ref name="MultilingualRenderingType"/>
@@ -692,6 +746,9 @@
692
746
  <optional>
693
747
  <attribute name="tag"/>
694
748
  </optional>
749
+ <optional>
750
+ <attribute name="type"/>
751
+ </optional>
695
752
  <optional>
696
753
  <attribute name="multilingual-rendering">
697
754
  <ref name="MultilingualRenderingType"/>
@@ -851,6 +908,16 @@
851
908
  <ref name="MultilingualRenderingType"/>
852
909
  </attribute>
853
910
  </optional>
911
+ <optional>
912
+ <attribute name="coverpage">
913
+ <data type="boolean"/>
914
+ </attribute>
915
+ </optional>
916
+ <optional>
917
+ <attribute name="notag">
918
+ <data type="boolean"/>
919
+ </attribute>
920
+ </optional>
854
921
  <oneOrMore>
855
922
  <choice>
856
923
  <ref name="paragraph"/>
@@ -1178,6 +1245,7 @@
1178
1245
  <ref name="concept"/>
1179
1246
  <ref name="add"/>
1180
1247
  <ref name="del"/>
1248
+ <ref name="span"/>
1181
1249
  </choice>
1182
1250
  </define>
1183
1251
  <define name="add">
@@ -1204,6 +1272,14 @@
1204
1272
  </choice>
1205
1273
  </element>
1206
1274
  </define>
1275
+ <define name="span">
1276
+ <element name="span">
1277
+ <attribute name="class"/>
1278
+ <oneOrMore>
1279
+ <ref name="TextElement"/>
1280
+ </oneOrMore>
1281
+ </element>
1282
+ </define>
1207
1283
  <define name="concept">
1208
1284
  <element name="concept">
1209
1285
  <optional>
@@ -1994,6 +2070,7 @@
1994
2070
  <value>compare</value>
1995
2071
  <value>contrast</value>
1996
2072
  <value>see</value>
2073
+ <value>seealso</value>
1997
2074
  </choice>
1998
2075
  </define>
1999
2076
  <define name="deprecates">
data/grammars/nist.rng CHANGED
@@ -19,6 +19,9 @@
19
19
  <value>steps</value>
20
20
  </attribute>
21
21
  </optional>
22
+ <optional>
23
+ <ref name="tname"/>
24
+ </optional>
22
25
  <oneOrMore>
23
26
  <ref name="li"/>
24
27
  </oneOrMore>
@@ -41,7 +41,7 @@ module RelatonNist
41
41
 
42
42
  def pub_id(doc)
43
43
  # anchor(doc).gsub(".", " ")
44
- fetch_doi(doc).split("/")[1..-1].join("/").gsub(".", " ")
44
+ fetch_doi(doc).split("/")[1..].join("/").gsub(".", " ")
45
45
  end
46
46
 
47
47
  def fetch_doi(doc) # rubocop:disable Metrics/CyclomaticComplexity
@@ -103,12 +103,14 @@ module RelatonNist
103
103
 
104
104
  # @param doc [Nokogiri::XML::Element]
105
105
  # @return [Array<Hash>]
106
- def fetch_relation(doc)
106
+ def fetch_relation(doc) # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
107
107
  ns = "http://www.crossref.org/relations.xsd"
108
108
  doc.xpath("./ns:program/ns:related_item", ns: ns).map do |rel|
109
109
  rdoi = rel.at_xpath("ns:intra_work_relation|ns:inter_work_relation", ns: ns)
110
- fref = RelatonBib::FormattedRef.new content: rdoi.text
111
- bibitem = RelatonBib::BibliographicItem.new formattedref: fref
110
+ id = rdoi.text.split("/")[1..].join("/").gsub(".", " ")
111
+ fref = RelatonBib::FormattedRef.new content: id
112
+ docid = RelatonBib::DocumentIdentifier.new(type: "NIST", id: id, primary: true)
113
+ bibitem = RelatonBib::BibliographicItem.new formattedref: fref, docid: [docid]
112
114
  type = RELATION_TYPES[rdoi["relationship-type"]]
113
115
  warn "Relation type #{rdoi['relationship-type']} not found" unless type
114
116
  { type: type, bibitem: bibitem }
@@ -158,20 +160,37 @@ module RelatonNist
158
160
  { entity: person, role: [{ type: p["contributor_role"] }] }
159
161
  end
160
162
  contribs + doc.xpath("publisher").map do |p|
161
- abbr = p.at("../institution/institution_acronym")&.text
162
- place = p.at("./publisher_place")
163
- cont = []
164
- if place
165
- city, state = place.text.split(", ")
166
- cont << RelatonBib::Address.new(street: [], city: city, state: state, country: "US")
167
- end
168
- org = RelatonBib::Organization.new(
169
- name: p.at("publisher_name").text, abbreviation: abbr, contact: cont,
170
- )
171
- { entity: org, role: [{ type: "publisher" }] }
163
+ { entity: create_org(p), role: [{ type: "publisher" }] }
164
+ end
165
+ end
166
+
167
+ #
168
+ # Create publisher organization
169
+ #
170
+ # @param [Nokogiri::XML::Element] pub publisher element
171
+ #
172
+ # @return [RelatonBib::Organization] publisher organization
173
+ #
174
+ def create_org(pub)
175
+ name = pub.at("publisher_name").text
176
+ abbr = pub.at("../institution[institution_name[.='#{name}']]/institution_acronym")&.text
177
+ place = pub.at("./publisher_place") ||
178
+ pub.at("../institution[institution_name[.='#{name}']]/institution_place")
179
+ cont = []
180
+ if place
181
+ city, state = place.text.split(", ")
182
+ cont << RelatonBib::Address.new(street: [], city: city, state: state, country: "US")
172
183
  end
184
+ RelatonBib::Organization.new name: name, abbreviation: abbr, contact: cont
173
185
  end
174
186
 
187
+ #
188
+ # Create affiliation organization
189
+ #
190
+ # @param [Nokogiri::XML::Element] doc affiliation element
191
+ #
192
+ # @return [Array<RelatonBib::Affiliation>] affiliation
193
+ #
175
194
  def affiliation(doc)
176
195
  doc.xpath("./institution/institution_department").map do |id|
177
196
  org = RelatonBib::Organization.new name: id.text
@@ -185,9 +204,20 @@ module RelatonNist
185
204
  doc.xpath("institution/institution_place").map(&:text)
186
205
  end
187
206
 
207
+ #
208
+ # Fetches series
209
+ #
210
+ # @param [Nokogiri::XML::Element] doc document element
211
+ #
212
+ # @return [Array<RelatonBib::Series>] series
213
+ #
188
214
  def fetch_series(doc)
189
- title = RelatonBib::TypedTitleString.new(content: "NIST")
190
- [RelatonBib::Series.new(title: title, number: pub_id(doc))]
215
+ series_path = File.expand_path("series.yaml", __dir__)
216
+ series = YAML.load_file series_path
217
+ prf, srs, = pub_id(doc).split
218
+ sname = series[srs] || srs
219
+ title = RelatonBib::TypedTitleString.new(content: "#{prf} #{sname}")
220
+ [RelatonBib::Series.new(title: title, number: "#{prf} #{srs}")]
191
221
  end
192
222
 
193
223
  #
@@ -221,8 +251,8 @@ module RelatonNist
221
251
  def parse_doc(doc) # rubocop:disable Metrics/MethodLength,Metrics/AbcSize
222
252
  # mtd = doc.at('doi_record/report-paper/report-paper_metadata')
223
253
  item = RelatonNist::NistBibliographicItem.new(
224
- type: "standard", docid: fetch_docid(doc), title: fetch_title(doc),
225
- link: fetch_link(doc), abstract: fetch_abstract(doc),
254
+ fetched: Date.today.to_s, type: "standard", docid: fetch_docid(doc),
255
+ title: fetch_title(doc), link: fetch_link(doc), abstract: fetch_abstract(doc),
226
256
  date: fetch_date(doc), edition: fetch_edition(doc),
227
257
  contributor: fetch_contributor(doc), relation: fetch_relation(doc),
228
258
  place: fetch_place(doc), series: fetch_series(doc),
@@ -5,7 +5,7 @@ module RelatonNist
5
5
  # @param args [Hash]
6
6
  # @param nested [TrueClass, FalseClass]
7
7
  # @return [Hash]
8
- def hash_to_bib(args, nested = false)
8
+ def hash_to_bib(args)
9
9
  ret = super
10
10
  return if ret.nil?
11
11
 
@@ -18,13 +18,13 @@ module RelatonNist
18
18
  # @param item_hash [Hash]
19
19
  # @return [RelatonNist::NistBibliographicItem]
20
20
  def bib_item(item_hash)
21
- NistBibliographicItem.new **item_hash
21
+ NistBibliographicItem.new(**item_hash)
22
22
  end
23
23
 
24
24
  def commentperiod_hash_to_bib(ret)
25
25
  return unless ret[:commentperiod]
26
26
 
27
- ret[:commentperiod] = CommentPeriod.new **ret[:commentperiod]
27
+ ret[:commentperiod] = CommentPeriod.new(**ret[:commentperiod])
28
28
  end
29
29
 
30
30
  # @param ret [Hash]
@@ -32,7 +32,7 @@ module RelatonNist
32
32
  super
33
33
  return unless ret[:relation]
34
34
 
35
- ret[:relation] = ret[:relation].map { |r| DocumentRelation.new **r }
35
+ ret[:relation] = ret[:relation].map { |r| DocumentRelation.new(**r) }
36
36
 
37
37
  # ret[:relation] = array(ret[:relation])
38
38
  # ret[:relation]&.each do |r|
@@ -0,0 +1,49 @@
1
+ ---
2
+ AMS: Advanced Manufacturing Series
3
+ BRPD: Basic Radio Propagation Predictions Series
4
+ BH: Building and Housing Reports
5
+ BMS: Building Materials and Structures Reports
6
+ BSS: Building Science Series
7
+ CRPL: CRPL Solar-Geophysical Data
8
+ IP: CRPL Ionospheric Predictions
9
+ CIRC: Circulars
10
+ CIS: Consumer Information Series
11
+ CS: Commercial Standards
12
+ CSM: Commercial Standards Monthly
13
+ CSWP: Cybersecurity White Papers
14
+ EAB: Economic Analysis Briefs
15
+ FIPS: Federal Information Processing Standards Publications
16
+ GCR: Grant/Contractor Reports
17
+ HB: Handbooks
18
+ HR: Hydraulic Research in the United States
19
+ IRPL: Interservice Radio Propagation Laboratory
20
+ LCIRC: Letter Circular
21
+ MONO: Monographs
22
+ MP: Miscellaneous Publications
23
+ NCSTAR: National Construction Safety Team Act Reports
24
+ NSRDS: National Standard Reference Data Series
25
+ IR: NISTIRs (Interagency/Internal Reports)
26
+ OWMWP: Office of Weights and Measures White Papers
27
+ PC: Photographic Circulars
28
+ RPT: NBS Reports
29
+ SIBS: Special Interior Ballistics Studies
30
+ SP: Special Publications (General)
31
+ SP250: 'SP 250: Calibration Services'
32
+ SP260: 'SP 260: Standard Reference Materials'
33
+ SP300: 'SP 300: Precision Measurement and Calibration'
34
+ SP400: 'SP 400: Semiconductor Measurement Technology'
35
+ SP480: 'SP 480: Law Enforcement Technology'
36
+ SP500: 'SP 500: Computer Systems Technology'
37
+ SP700: 'SP 700: Industrial Measurement Series'
38
+ SP800: 'SP 800: Computer Security Series'
39
+ SP823: 'SP 823: Integrated Services Digital Network Series'
40
+ SP960: 'SP 960: NIST Recommended Practice Guides'
41
+ SP1200: 'SP 1200: Protocols'
42
+ SP1500: 'SP 1500: Working Group Papers'
43
+ SP1800: 'SP 1800: NIST Cybersecurity Practice Guides'
44
+ SP1900: 'SP 1900: Cyber-Physical Systems'
45
+ SP2000: 'SP 2000: Standards Coordination'
46
+ SP2100: 'SP 2100: Conference Proceedings'
47
+ TIBM: Technical Information on Building Materials
48
+ TN: Technical Notes
49
+ TTB: Technology Transfer Brief
@@ -1,3 +1,3 @@
1
1
  module RelatonNist
2
- VERSION = "1.11.2".freeze
2
+ VERSION = "1.12.0".freeze
3
3
  end
data/relaton_nist.gemspec CHANGED
@@ -21,7 +21,7 @@ Gem::Specification.new do |spec|
21
21
  spec.bindir = "exe"
22
22
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
23
23
  spec.require_paths = ["lib"]
24
- spec.required_ruby_version = Gem::Requirement.new(">= 2.5.0")
24
+ spec.required_ruby_version = Gem::Requirement.new(">= 2.6.0")
25
25
 
26
26
  spec.add_development_dependency "equivalent-xml", "~> 0.6"
27
27
  spec.add_development_dependency "pry-byebug"
@@ -32,6 +32,6 @@ Gem::Specification.new do |spec|
32
32
  spec.add_development_dependency "vcr"
33
33
  spec.add_development_dependency "webmock"
34
34
 
35
- spec.add_dependency "relaton-bib", "~> 1.11.0"
35
+ spec.add_dependency "relaton-bib", "~> 1.12.0"
36
36
  spec.add_dependency "rubyzip"
37
37
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relaton-nist
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.11.2
4
+ version: 1.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-05-06 00:00:00.000000000 Z
11
+ date: 2022-06-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: equivalent-xml
@@ -128,14 +128,14 @@ dependencies:
128
128
  requirements:
129
129
  - - "~>"
130
130
  - !ruby/object:Gem::Version
131
- version: 1.11.0
131
+ version: 1.12.0
132
132
  type: :runtime
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - "~>"
137
137
  - !ruby/object:Gem::Version
138
- version: 1.11.0
138
+ version: 1.12.0
139
139
  - !ruby/object:Gem::Dependency
140
140
  name: rubyzip
141
141
  requirement: !ruby/object:Gem::Requirement
@@ -185,6 +185,7 @@ files:
185
185
  - lib/relaton_nist/nist_bibliography.rb
186
186
  - lib/relaton_nist/processor.rb
187
187
  - lib/relaton_nist/scrapper.rb
188
+ - lib/relaton_nist/series.yaml
188
189
  - lib/relaton_nist/version.rb
189
190
  - lib/relaton_nist/xml_parser.rb
190
191
  - relaton_nist.gemspec
@@ -201,7 +202,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
201
202
  requirements:
202
203
  - - ">="
203
204
  - !ruby/object:Gem::Version
204
- version: 2.5.0
205
+ version: 2.6.0
205
206
  required_rubygems_version: !ruby/object:Gem::Requirement
206
207
  requirements:
207
208
  - - ">="