sts 0.5.7 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/TODO.sts-refactor/00-overview.md +24 -4
- data/TODO.sts-refactor/03-namespace-coupling.md +108 -147
- data/lib/sts/iso_sts/alt_text.rb +23 -0
- data/lib/sts/iso_sts/app.rb +1 -1
- data/lib/sts/iso_sts/array.rb +1 -1
- data/lib/sts/iso_sts/disp_formula.rb +1 -1
- data/lib/sts/iso_sts/doc_number.rb +16 -0
- data/lib/sts/iso_sts/doc_type.rb +16 -0
- data/lib/sts/iso_sts/document_identification.rb +4 -4
- data/lib/sts/iso_sts/fpage.rb +23 -0
- data/lib/sts/iso_sts/graphic.rb +2 -2
- data/lib/sts/iso_sts/ics.rb +16 -0
- data/lib/sts/iso_sts/is_proof.rb +13 -0
- data/lib/sts/iso_sts/iso_meta.rb +3 -3
- data/lib/sts/iso_sts/issue.rb +23 -0
- data/lib/sts/iso_sts/long_desc.rb +23 -0
- data/lib/sts/iso_sts/lpage.rb +21 -0
- data/lib/sts/iso_sts/mixed_citation.rb +7 -7
- data/lib/sts/iso_sts/nat_meta.rb +3 -3
- data/lib/sts/iso_sts/originator.rb +16 -0
- data/lib/sts/iso_sts/page_range.rb +21 -0
- data/lib/sts/iso_sts/part_number.rb +16 -0
- data/lib/sts/iso_sts/proj_id.rb +16 -0
- data/lib/sts/iso_sts/pub_date.rb +17 -0
- data/lib/sts/iso_sts/pub_id.rb +19 -0
- data/lib/sts/iso_sts/reg_meta.rb +5 -5
- data/lib/sts/iso_sts/release_version.rb +16 -0
- data/lib/sts/{tbx_iso_tml/mi.rb → iso_sts/release_version_id.rb} +5 -7
- data/lib/sts/iso_sts/sdo.rb +16 -0
- data/lib/sts/iso_sts/secretariat.rb +3 -4
- data/lib/sts/iso_sts/standard.rb +1 -0
- data/lib/sts/iso_sts/standard_identification.rb +8 -8
- data/lib/sts/iso_sts/std_ref.rb +7 -7
- data/lib/sts/iso_sts/styled_content.rb +0 -2
- data/lib/sts/iso_sts/suppl_number.rb +16 -0
- data/lib/sts/iso_sts/suppl_type.rb +16 -0
- data/lib/sts/iso_sts/suppl_version.rb +16 -0
- data/lib/sts/iso_sts/table_wrap_foot.rb +1 -1
- data/lib/sts/iso_sts/tex_math.rb +23 -0
- data/lib/sts/iso_sts/urn.rb +16 -0
- data/lib/sts/iso_sts/version.rb +16 -0
- data/lib/sts/iso_sts/volume.rb +23 -0
- data/lib/sts/iso_sts/wi_number.rb +19 -0
- data/lib/sts/iso_sts/year.rb +21 -0
- data/lib/sts/iso_sts.rb +27 -0
- data/lib/sts/niso_sts/display_formula.rb +1 -3
- data/lib/sts/niso_sts/inline_formula.rb +1 -3
- data/lib/sts/niso_sts/standard.rb +1 -0
- data/lib/sts/tbx_iso_tml/definition.rb +1 -1
- data/lib/sts/tbx_iso_tml/note.rb +1 -1
- data/lib/sts/tbx_iso_tml/term.rb +1 -1
- data/lib/sts/tbx_iso_tml.rb +0 -12
- data/lib/sts/version.rb +1 -1
- data/lib/sts.rb +1 -1
- metadata +29 -15
- data/lib/sts/mathml.rb +0 -21
- data/lib/sts/tbx_iso_tml/math.rb +0 -49
- data/lib/sts/tbx_iso_tml/mfenced.rb +0 -40
- data/lib/sts/tbx_iso_tml/mfrac.rb +0 -30
- data/lib/sts/tbx_iso_tml/mrow.rb +0 -41
- data/lib/sts/tbx_iso_tml/mspace.rb +0 -18
- data/lib/sts/tbx_iso_tml/mstyle.rb +0 -29
- data/lib/sts/tbx_iso_tml/msub.rb +0 -31
- data/lib/sts/tbx_iso_tml/msup.rb +0 -25
- data/lib/sts/tbx_iso_tml/munder.rb +0 -19
- data/lib/sts/tbx_iso_tml/munderover.rb +0 -23
- data/lib/sts/tbx_iso_tml/semantics.rb +0 -27
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <originator> as type="xs:string" -- no attributes.
|
|
6
|
+
class Originator < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "originator"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
class PageRange < Lutaml::Model::Serializable
|
|
6
|
+
attribute :content, :string
|
|
7
|
+
attribute :content_type, :string
|
|
8
|
+
attribute :specific_use, :string
|
|
9
|
+
attribute :xml_lang, :string
|
|
10
|
+
|
|
11
|
+
xml do
|
|
12
|
+
element "page-range"
|
|
13
|
+
|
|
14
|
+
map_content to: :content
|
|
15
|
+
map_attribute "content-type", to: :content_type
|
|
16
|
+
map_attribute "specific-use", to: :specific_use
|
|
17
|
+
map_attribute "xml:lang", to: :xml_lang
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <part-number> as type="xs:string" -- no attributes.
|
|
6
|
+
class PartNumber < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "part-number"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <proj-id> as type="xs:string" -- no attributes.
|
|
6
|
+
class ProjId < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "proj-id"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
class PubDate < Lutaml::Model::Serializable
|
|
6
|
+
attribute :content, :string
|
|
7
|
+
attribute :pub_type, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "pub-date"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
map_attribute "pub-type", to: :pub_type
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
class PubId < Lutaml::Model::Serializable
|
|
6
|
+
attribute :content, :string
|
|
7
|
+
attribute :pub_id_type, :string
|
|
8
|
+
attribute :specific_use, :string
|
|
9
|
+
|
|
10
|
+
xml do
|
|
11
|
+
element "pub-id"
|
|
12
|
+
|
|
13
|
+
map_content to: :content
|
|
14
|
+
map_attribute "pub-id-type", to: :pub_id_type
|
|
15
|
+
map_attribute "specific-use", to: :specific_use
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
19
|
+
end
|
data/lib/sts/iso_sts/reg_meta.rb
CHANGED
|
@@ -14,8 +14,8 @@ module Sts
|
|
|
14
14
|
attribute :doc_ref, :string
|
|
15
15
|
attribute :release_date, ::Sts::IsoSts::ReleaseDate
|
|
16
16
|
attribute :comm_ref, :string
|
|
17
|
-
attribute :secretariat, ::Sts::
|
|
18
|
-
attribute :ics, ::Sts::
|
|
17
|
+
attribute :secretariat, ::Sts::IsoSts::Secretariat, collection: true
|
|
18
|
+
attribute :ics, ::Sts::IsoSts::Ics, collection: true
|
|
19
19
|
attribute :page_count, ::Sts::IsoSts::PageCount
|
|
20
20
|
attribute :permissions, ::Sts::IsoSts::Permissions, collection: true
|
|
21
21
|
attribute :std_xref, ::Sts::IsoSts::StandardCrossReference,
|
|
@@ -23,9 +23,9 @@ module Sts
|
|
|
23
23
|
attribute :custom_meta_group, ::Sts::NisoSts::CustomMetaGroup,
|
|
24
24
|
collection: true
|
|
25
25
|
attribute :meta_date, ::Sts::IsoSts::MetaDate, collection: true
|
|
26
|
-
attribute :pub_date, ::Sts::
|
|
27
|
-
attribute :wi_number,
|
|
28
|
-
attribute :release_version_id, ::Sts::
|
|
26
|
+
attribute :pub_date, ::Sts::IsoSts::PubDate
|
|
27
|
+
attribute :wi_number, ::Sts::IsoSts::WiNumber
|
|
28
|
+
attribute :release_version_id, ::Sts::IsoSts::ReleaseVersionId
|
|
29
29
|
|
|
30
30
|
xml do
|
|
31
31
|
element "reg-meta"
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <release-version> as type="xs:string" -- no attributes.
|
|
6
|
+
class ReleaseVersion < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "release-version"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -1,18 +1,16 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
module Sts
|
|
4
|
-
module
|
|
5
|
-
class
|
|
6
|
-
attribute :id, :string
|
|
4
|
+
module IsoSts
|
|
5
|
+
class ReleaseVersionId < Lutaml::Model::Serializable
|
|
7
6
|
attribute :content, :string
|
|
7
|
+
attribute :id, :string
|
|
8
8
|
|
|
9
9
|
xml do
|
|
10
|
-
element "
|
|
11
|
-
|
|
12
|
-
map_attribute "id", to: :id
|
|
13
|
-
namespace ::Sts::Namespaces::MathmlNamespace
|
|
10
|
+
element "release-version-id"
|
|
14
11
|
|
|
15
12
|
map_content to: :content
|
|
13
|
+
map_attribute "id", to: :id
|
|
16
14
|
end
|
|
17
15
|
end
|
|
18
16
|
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <sdo> as type="xs:string" -- no attributes.
|
|
6
|
+
class Sdo < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "sdo"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -2,13 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
module Sts
|
|
4
4
|
module IsoSts
|
|
5
|
+
# ISOSTS declares <secretariat> as type="xs:string" -- no attributes.
|
|
5
6
|
class Secretariat < Lutaml::Model::Serializable
|
|
6
|
-
attribute :
|
|
7
|
-
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
8
9
|
xml do
|
|
9
10
|
element "secretariat"
|
|
10
|
-
map_attribute "id", to: :id
|
|
11
|
-
mixed_content
|
|
12
11
|
|
|
13
12
|
map_content to: :content
|
|
14
13
|
end
|
data/lib/sts/iso_sts/standard.rb
CHANGED
|
@@ -4,15 +4,15 @@ module Sts
|
|
|
4
4
|
module IsoSts
|
|
5
5
|
class StandardIdentification < Lutaml::Model::Serializable
|
|
6
6
|
attribute :id, :string
|
|
7
|
-
attribute :originator, ::Sts::
|
|
8
|
-
attribute :doc_type, ::Sts::
|
|
9
|
-
attribute :doc_number, ::Sts::
|
|
10
|
-
attribute :part_number, ::Sts::
|
|
7
|
+
attribute :originator, ::Sts::IsoSts::Originator
|
|
8
|
+
attribute :doc_type, ::Sts::IsoSts::DocType
|
|
9
|
+
attribute :doc_number, ::Sts::IsoSts::DocNumber
|
|
10
|
+
attribute :part_number, ::Sts::IsoSts::PartNumber
|
|
11
11
|
attribute :edition, ::Sts::IsoSts::Edition
|
|
12
|
-
attribute :version, ::Sts::
|
|
13
|
-
attribute :suppl_type, ::Sts::
|
|
14
|
-
attribute :suppl_number, ::Sts::
|
|
15
|
-
attribute :suppl_version, ::Sts::
|
|
12
|
+
attribute :version, ::Sts::IsoSts::Version
|
|
13
|
+
attribute :suppl_type, ::Sts::IsoSts::SupplType
|
|
14
|
+
attribute :suppl_number, ::Sts::IsoSts::SupplNumber
|
|
15
|
+
attribute :suppl_version, ::Sts::IsoSts::SupplVersion
|
|
16
16
|
|
|
17
17
|
xml do
|
|
18
18
|
element "std-ident"
|
data/lib/sts/iso_sts/std_ref.rb
CHANGED
|
@@ -5,14 +5,14 @@ module Sts
|
|
|
5
5
|
class StdRef < Lutaml::Model::Serializable
|
|
6
6
|
attribute :id, :string
|
|
7
7
|
attribute :type, :string
|
|
8
|
-
attribute :originator, ::Sts::
|
|
9
|
-
attribute :doc_type, ::Sts::
|
|
10
|
-
attribute :doc_number, ::Sts::
|
|
11
|
-
attribute :part_number, ::Sts::
|
|
8
|
+
attribute :originator, ::Sts::IsoSts::Originator
|
|
9
|
+
attribute :doc_type, ::Sts::IsoSts::DocType
|
|
10
|
+
attribute :doc_number, ::Sts::IsoSts::DocNumber
|
|
11
|
+
attribute :part_number, ::Sts::IsoSts::PartNumber
|
|
12
12
|
attribute :edition, ::Sts::IsoSts::Edition
|
|
13
|
-
attribute :suppl_type, ::Sts::
|
|
14
|
-
attribute :suppl_number, ::Sts::
|
|
15
|
-
attribute :year, ::Sts::
|
|
13
|
+
attribute :suppl_type, ::Sts::IsoSts::SupplType
|
|
14
|
+
attribute :suppl_number, ::Sts::IsoSts::SupplNumber
|
|
15
|
+
attribute :year, ::Sts::IsoSts::Year
|
|
16
16
|
attribute :content, :string, collection: true
|
|
17
17
|
xml do
|
|
18
18
|
element "std-ref"
|
|
@@ -25,7 +25,6 @@ module Sts
|
|
|
25
25
|
attribute :sc, ::Sts::IsoSts::Sc, collection: true
|
|
26
26
|
attribute :strike, ::Sts::IsoSts::Strike, collection: true
|
|
27
27
|
attribute :underline, ::Sts::IsoSts::Underline, collection: true
|
|
28
|
-
attribute :ruby, ::Sts::NisoSts::Ruby, collection: true
|
|
29
28
|
attribute :break, ::Sts::IsoSts::Break, collection: true
|
|
30
29
|
attribute :styled_content, ::Sts::IsoSts::StyledContent, collection: true
|
|
31
30
|
|
|
@@ -57,7 +56,6 @@ module Sts
|
|
|
57
56
|
map_element "sc", to: :sc
|
|
58
57
|
map_element "strike", to: :strike
|
|
59
58
|
map_element "underline", to: :underline
|
|
60
|
-
map_element "ruby", to: :ruby
|
|
61
59
|
map_element "break", to: :break
|
|
62
60
|
map_element "styled-content", to: :styled_content
|
|
63
61
|
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <suppl-number> as type="xs:string" -- no attributes.
|
|
6
|
+
class SupplNumber < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "suppl-number"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <suppl-type> as type="xs:string" -- no attributes.
|
|
6
|
+
class SupplType < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "suppl-type"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <suppl-version> as type="xs:string" -- no attributes.
|
|
6
|
+
class SupplVersion < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "suppl-version"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -11,7 +11,7 @@ module Sts
|
|
|
11
11
|
attribute :fn_group, ::Sts::IsoSts::FnGroup
|
|
12
12
|
attribute :fn, ::Sts::IsoSts::Fn
|
|
13
13
|
attribute :attrib, ::Sts::NisoSts::Attrib
|
|
14
|
-
attribute :permissions, ::Sts::
|
|
14
|
+
attribute :permissions, ::Sts::IsoSts::Permissions
|
|
15
15
|
|
|
16
16
|
xml do
|
|
17
17
|
element "table-wrap-foot"
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
class TexMath < Lutaml::Model::Serializable
|
|
6
|
+
attribute :content, :string
|
|
7
|
+
attribute :id, :string
|
|
8
|
+
attribute :content_type, :string
|
|
9
|
+
attribute :notation, :string
|
|
10
|
+
attribute :version, :string
|
|
11
|
+
|
|
12
|
+
xml do
|
|
13
|
+
element "tex-math"
|
|
14
|
+
|
|
15
|
+
map_content to: :content
|
|
16
|
+
map_attribute "id", to: :id
|
|
17
|
+
map_attribute "content-type", to: :content_type
|
|
18
|
+
map_attribute "notation", to: :notation
|
|
19
|
+
map_attribute "version", to: :version
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
23
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <urn> as type="xs:string" -- no attributes.
|
|
6
|
+
class Urn < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "urn"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <version> as type="xs:string" -- no attributes.
|
|
6
|
+
class Version < Lutaml::Model::Serializable
|
|
7
|
+
attribute :content, :string
|
|
8
|
+
|
|
9
|
+
xml do
|
|
10
|
+
element "version"
|
|
11
|
+
|
|
12
|
+
map_content to: :content
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
end
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
class Volume < Lutaml::Model::Serializable
|
|
6
|
+
attribute :content, :string
|
|
7
|
+
attribute :content_type, :string
|
|
8
|
+
attribute :seq, :string
|
|
9
|
+
attribute :specific_use, :string
|
|
10
|
+
attribute :xml_lang, :string
|
|
11
|
+
|
|
12
|
+
xml do
|
|
13
|
+
element "volume"
|
|
14
|
+
|
|
15
|
+
map_content to: :content
|
|
16
|
+
map_attribute "content-type", to: :content_type
|
|
17
|
+
map_attribute "seq", to: :seq
|
|
18
|
+
map_attribute "specific-use", to: :specific_use
|
|
19
|
+
map_attribute "xml:lang", to: :xml_lang
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
23
|
+
end
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
# ISOSTS declares <wi-number> as mixed content carrying an @id. Modelling it
|
|
6
|
+
# as a plain string silently discarded that @id.
|
|
7
|
+
class WiNumber < Lutaml::Model::Serializable
|
|
8
|
+
attribute :content, :string
|
|
9
|
+
attribute :id, :string
|
|
10
|
+
|
|
11
|
+
xml do
|
|
12
|
+
element "wi-number"
|
|
13
|
+
|
|
14
|
+
map_content to: :content
|
|
15
|
+
map_attribute "id", to: :id
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
19
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Sts
|
|
4
|
+
module IsoSts
|
|
5
|
+
class Year < Lutaml::Model::Serializable
|
|
6
|
+
attribute :content, :string
|
|
7
|
+
attribute :content_type, :string
|
|
8
|
+
attribute :specific_use, :string
|
|
9
|
+
attribute :xml_lang, :string
|
|
10
|
+
|
|
11
|
+
xml do
|
|
12
|
+
element "year"
|
|
13
|
+
|
|
14
|
+
map_content to: :content
|
|
15
|
+
map_attribute "content-type", to: :content_type
|
|
16
|
+
map_attribute "specific-use", to: :specific_use
|
|
17
|
+
map_attribute "xml:lang", to: :xml_lang
|
|
18
|
+
end
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
data/lib/sts/iso_sts.rb
CHANGED
|
@@ -38,6 +38,33 @@ module Sts
|
|
|
38
38
|
autoload :MetaDate, "#{__dir__}/iso_sts/meta_date"
|
|
39
39
|
autoload :ContentLanguage, "#{__dir__}/iso_sts/content_language"
|
|
40
40
|
autoload :StandardRef, "#{__dir__}/iso_sts/standard_ref"
|
|
41
|
+
autoload :WiNumber, "#{__dir__}/iso_sts/wi_number"
|
|
42
|
+
autoload :Originator, "#{__dir__}/iso_sts/originator"
|
|
43
|
+
autoload :DocType, "#{__dir__}/iso_sts/doc_type"
|
|
44
|
+
autoload :DocNumber, "#{__dir__}/iso_sts/doc_number"
|
|
45
|
+
autoload :PartNumber, "#{__dir__}/iso_sts/part_number"
|
|
46
|
+
autoload :Version, "#{__dir__}/iso_sts/version"
|
|
47
|
+
autoload :SupplType, "#{__dir__}/iso_sts/suppl_type"
|
|
48
|
+
autoload :SupplNumber, "#{__dir__}/iso_sts/suppl_number"
|
|
49
|
+
autoload :SupplVersion, "#{__dir__}/iso_sts/suppl_version"
|
|
50
|
+
autoload :Urn, "#{__dir__}/iso_sts/urn"
|
|
51
|
+
autoload :Sdo, "#{__dir__}/iso_sts/sdo"
|
|
52
|
+
autoload :ProjId, "#{__dir__}/iso_sts/proj_id"
|
|
53
|
+
autoload :ReleaseVersion, "#{__dir__}/iso_sts/release_version"
|
|
54
|
+
autoload :Ics, "#{__dir__}/iso_sts/ics"
|
|
55
|
+
autoload :Year, "#{__dir__}/iso_sts/year"
|
|
56
|
+
autoload :PubDate, "#{__dir__}/iso_sts/pub_date"
|
|
57
|
+
autoload :ReleaseVersionId, "#{__dir__}/iso_sts/release_version_id"
|
|
58
|
+
autoload :IsProof, "#{__dir__}/iso_sts/is_proof"
|
|
59
|
+
autoload :AltText, "#{__dir__}/iso_sts/alt_text"
|
|
60
|
+
autoload :LongDesc, "#{__dir__}/iso_sts/long_desc"
|
|
61
|
+
autoload :TexMath, "#{__dir__}/iso_sts/tex_math"
|
|
62
|
+
autoload :PubId, "#{__dir__}/iso_sts/pub_id"
|
|
63
|
+
autoload :Volume, "#{__dir__}/iso_sts/volume"
|
|
64
|
+
autoload :Issue, "#{__dir__}/iso_sts/issue"
|
|
65
|
+
autoload :Fpage, "#{__dir__}/iso_sts/fpage"
|
|
66
|
+
autoload :Lpage, "#{__dir__}/iso_sts/lpage"
|
|
67
|
+
autoload :PageRange, "#{__dir__}/iso_sts/page_range"
|
|
41
68
|
|
|
42
69
|
# Section elements
|
|
43
70
|
autoload :Sec, "#{__dir__}/iso_sts/sec"
|
|
@@ -20,7 +20,7 @@ module Sts
|
|
|
20
20
|
attribute :named_content, ::Sts::NisoSts::NamedContent, collection: true
|
|
21
21
|
attribute :styled_content, ::Sts::NisoSts::StyledContent, collection: true
|
|
22
22
|
attribute :label, ::Sts::NisoSts::Label
|
|
23
|
-
attribute :math, ::
|
|
23
|
+
attribute :math, ::Mml::V3::Math
|
|
24
24
|
attribute :inline_formula, ::Sts::NisoSts::InlineFormula, collection: true
|
|
25
25
|
attribute :tex_math, ::Sts::NisoSts::TexMath
|
|
26
26
|
attribute :graphic, ::Sts::NisoSts::Graphic, collection: true
|
|
@@ -32,7 +32,6 @@ module Sts
|
|
|
32
32
|
|
|
33
33
|
xml do
|
|
34
34
|
element "disp-formula"
|
|
35
|
-
mixed_content
|
|
36
35
|
|
|
37
36
|
map_attribute "id", to: :id
|
|
38
37
|
map_attribute "content-type", to: :content_type
|
|
@@ -40,7 +39,6 @@ module Sts
|
|
|
40
39
|
map_attribute "specific-use", to: :specific_use
|
|
41
40
|
map_attribute "xml:lang", to: :xml_lang
|
|
42
41
|
|
|
43
|
-
map_content to: :content
|
|
44
42
|
map_element "bold", to: :bold
|
|
45
43
|
map_element "italic", to: :italic
|
|
46
44
|
map_element "sub", to: :sub
|
|
@@ -16,7 +16,7 @@ module Sts
|
|
|
16
16
|
attribute :private_char, ::Sts::NisoSts::PrivateChar, collection: true
|
|
17
17
|
attribute :named_content, ::Sts::NisoSts::NamedContent, collection: true
|
|
18
18
|
attribute :styled_content, ::Sts::NisoSts::StyledContent, collection: true
|
|
19
|
-
attribute :math, ::
|
|
19
|
+
attribute :math, ::Mml::V3::Math
|
|
20
20
|
attribute :inline_formula, ::Sts::NisoSts::InlineFormula, collection: true
|
|
21
21
|
attribute :alternatives, ::Sts::NisoSts::Alternatives
|
|
22
22
|
attribute :preformat, ::Sts::NisoSts::Preformat
|
|
@@ -25,14 +25,12 @@ module Sts
|
|
|
25
25
|
|
|
26
26
|
xml do
|
|
27
27
|
element "inline-formula"
|
|
28
|
-
mixed_content
|
|
29
28
|
|
|
30
29
|
map_attribute "content-type", to: :content_type
|
|
31
30
|
map_attribute "id", to: :id
|
|
32
31
|
map_attribute "specific-use", to: :specific_use
|
|
33
32
|
map_attribute "xml:lang", to: :xml_lang
|
|
34
33
|
|
|
35
|
-
map_content to: :content
|
|
36
34
|
map_element "bold", to: :bold
|
|
37
35
|
map_element "italic", to: :italic
|
|
38
36
|
map_element "sub", to: :sub
|
|
@@ -8,7 +8,7 @@ module Sts
|
|
|
8
8
|
attribute :note, ::Sts::TbxIsoTml::Note
|
|
9
9
|
attribute :value, :string, collection: true
|
|
10
10
|
attribute :italic, ::Sts::TbxIsoTml::Italic, collection: true
|
|
11
|
-
attribute :math, ::
|
|
11
|
+
attribute :math, ::Mml::V3::Math
|
|
12
12
|
attribute :sub, ::Sts::NisoSts::Sub, collection: true
|
|
13
13
|
attribute :list, ::Sts::NisoSts::List, collection: true
|
|
14
14
|
attribute :std, ::Sts::NisoSts::ReferenceStandard, collection: true
|
data/lib/sts/tbx_iso_tml/note.rb
CHANGED
|
@@ -7,7 +7,7 @@ module Sts
|
|
|
7
7
|
attribute :value, :string, collection: true
|
|
8
8
|
attribute :table_wrap, ::Sts::TbxIsoTml::TableWrap
|
|
9
9
|
attribute :entailed_term, ::Sts::TbxIsoTml::EntailedTerm, collection: true
|
|
10
|
-
attribute :math, ::
|
|
10
|
+
attribute :math, ::Mml::V3::Math, collection: true
|
|
11
11
|
attribute :xref, ::Sts::TbxIsoTml::Xref, collection: true
|
|
12
12
|
attribute :list, ::Sts::NisoSts::List, collection: true
|
|
13
13
|
attribute :std, ::Sts::NisoSts::ReferenceStandard, collection: true
|
data/lib/sts/tbx_iso_tml/term.rb
CHANGED
|
@@ -10,7 +10,7 @@ module Sts
|
|
|
10
10
|
attribute :bold, ::Sts::TbxIsoTml::Bold, collection: true
|
|
11
11
|
attribute :sub, ::Sts::NisoSts::Sub, collection: true
|
|
12
12
|
attribute :sup, ::Sts::NisoSts::Sup, collection: true
|
|
13
|
-
attribute :math, ::
|
|
13
|
+
attribute :math, ::Mml::V3::Math, collection: true
|
|
14
14
|
attribute :xref, ::Sts::TbxIsoTml::Xref, collection: true
|
|
15
15
|
attribute :inline_formula, ::Sts::NisoSts::InlineFormula, collection: true
|
|
16
16
|
attribute :std, ::Sts::NisoSts::ReferenceStandard, collection: true
|
data/lib/sts/tbx_iso_tml.rb
CHANGED
|
@@ -18,24 +18,12 @@ module Sts
|
|
|
18
18
|
autoload :GrammaticalNumber, "#{__dir__}/tbx_iso_tml/grammatical_number"
|
|
19
19
|
autoload :Italic, "#{__dir__}/tbx_iso_tml/italic"
|
|
20
20
|
autoload :LangSet, "#{__dir__}/tbx_iso_tml/lang_set"
|
|
21
|
-
autoload :Math, "#{__dir__}/tbx_iso_tml/math"
|
|
22
|
-
autoload :Mfenced, "#{__dir__}/tbx_iso_tml/mfenced"
|
|
23
|
-
autoload :Mfrac, "#{__dir__}/tbx_iso_tml/mfrac"
|
|
24
|
-
autoload :Mi, "#{__dir__}/tbx_iso_tml/mi"
|
|
25
|
-
autoload :Mrow, "#{__dir__}/tbx_iso_tml/mrow"
|
|
26
|
-
autoload :Mspace, "#{__dir__}/tbx_iso_tml/mspace"
|
|
27
|
-
autoload :Mstyle, "#{__dir__}/tbx_iso_tml/mstyle"
|
|
28
|
-
autoload :Msub, "#{__dir__}/tbx_iso_tml/msub"
|
|
29
|
-
autoload :Msup, "#{__dir__}/tbx_iso_tml/msup"
|
|
30
|
-
autoload :Munder, "#{__dir__}/tbx_iso_tml/munder"
|
|
31
|
-
autoload :Munderover, "#{__dir__}/tbx_iso_tml/munderover"
|
|
32
21
|
autoload :NormativeAuthorization,
|
|
33
22
|
"#{__dir__}/tbx_iso_tml/normative_authorization"
|
|
34
23
|
autoload :Note, "#{__dir__}/tbx_iso_tml/note"
|
|
35
24
|
autoload :PartOfSpeech, "#{__dir__}/tbx_iso_tml/part_of_speech"
|
|
36
25
|
autoload :Pronunciation, "#{__dir__}/tbx_iso_tml/pronunciation"
|
|
37
26
|
autoload :See, "#{__dir__}/tbx_iso_tml/see"
|
|
38
|
-
autoload :Semantics, "#{__dir__}/tbx_iso_tml/semantics"
|
|
39
27
|
autoload :Source, "#{__dir__}/tbx_iso_tml/source"
|
|
40
28
|
autoload :SubjectField, "#{__dir__}/tbx_iso_tml/subject_field"
|
|
41
29
|
autoload :Sup, "#{__dir__}/tbx_iso_tml/sup"
|
data/lib/sts/version.rb
CHANGED
data/lib/sts.rb
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
require "lutaml/model"
|
|
4
|
+
require "mml"
|
|
4
5
|
|
|
5
6
|
module Sts
|
|
6
7
|
autoload :IsoSts, "#{__dir__}/sts/iso_sts"
|
|
7
|
-
autoload :Mathml, "#{__dir__}/sts/mathml"
|
|
8
8
|
autoload :Namespaces, "#{__dir__}/sts/namespaces"
|
|
9
9
|
autoload :NisoSts, "#{__dir__}/sts/niso_sts"
|
|
10
10
|
autoload :Profiles, "#{__dir__}/sts/profiles"
|