lutaml 0.9.8 → 0.9.9
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/lutaml/version.rb +1 -1
- data/lib/lutaml/xmi/parsers/xml.rb +2 -10
- data/lutaml.gemspec +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6cdc354ae49059f9158e3bfb8d0e7813b6c61d0084fa42ed7071026a9e62d311
|
4
|
+
data.tar.gz: 30c6683d8e22d2e1ded1b8ca53d3d63e5129025049314b036b678efb611f713e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1578a3589e20f92586cf4a60a6585ce5b758262a1112e3e5598e33c3209de72d477bf66b0fefd017e4633bd065ef93ed3fe37e2b55f60aae50a78203f299bcfa
|
7
|
+
data.tar.gz: 72883f24b869448ac32f8724cb05cd5d24acf88ecbaa066bf084724f57ac116567266257f317b0e284e8ab081519eae6d8a2108915fb4e680076990b43339576
|
data/lib/lutaml/version.rb
CHANGED
@@ -20,15 +20,8 @@ module Lutaml
|
|
20
20
|
# @param options [Hash] options for parsing
|
21
21
|
# @return [Lutaml::Uml::Document]
|
22
22
|
def self.parse(xml, _options = {})
|
23
|
-
sparx_root = Xmi::Sparx::SparxRoot
|
24
|
-
xmi_doc = Nokogiri::XML(File.read(xml))
|
25
|
-
namespace = xmi_doc.at_xpath("//xmi:XMI").namespaces
|
26
|
-
if namespace["xmlns:uml"].split("/").last == "20131001"
|
27
|
-
sparx_root = Xmi::Sparx::SparxRoot2013
|
28
|
-
end
|
29
|
-
|
30
23
|
xml_content = File.read(xml)
|
31
|
-
xmi_model =
|
24
|
+
xmi_model = Xmi::Sparx::SparxRoot.parse_xml(xml_content)
|
32
25
|
new.parse(xmi_model)
|
33
26
|
end
|
34
27
|
|
@@ -630,8 +623,7 @@ module Lutaml
|
|
630
623
|
def select_all_packaged_elements(all_elements, model, type)
|
631
624
|
select_all_items(all_elements, model, type, :packaged_element)
|
632
625
|
all_elements.delete_if do |e|
|
633
|
-
!e.is_a?(Xmi::Uml::PackagedElement)
|
634
|
-
!e.is_a?(Xmi::Uml::PackagedElement2013)
|
626
|
+
!e.is_a?(Xmi::Uml::PackagedElement)
|
635
627
|
end
|
636
628
|
end
|
637
629
|
|
data/lutaml.gemspec
CHANGED
@@ -36,7 +36,7 @@ Gem::Specification.new do |spec|
|
|
36
36
|
spec.add_runtime_dependency "parslet", "~> 2.0.0"
|
37
37
|
spec.add_runtime_dependency "ruby-graphviz", "~> 1.2"
|
38
38
|
spec.add_runtime_dependency "thor", "~> 1.0"
|
39
|
-
spec.add_runtime_dependency "xmi", "
|
39
|
+
spec.add_runtime_dependency "xmi", "~> 0.3.10"
|
40
40
|
|
41
41
|
spec.add_development_dependency "byebug"
|
42
42
|
spec.add_development_dependency "equivalent-xml", "~> 0.6.0"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lutaml
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: expressir
|
@@ -112,16 +112,16 @@ dependencies:
|
|
112
112
|
name: xmi
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
114
114
|
requirements:
|
115
|
-
- - "
|
115
|
+
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version: 0.3.
|
117
|
+
version: 0.3.10
|
118
118
|
type: :runtime
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
|
-
- - "
|
122
|
+
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version: 0.3.
|
124
|
+
version: 0.3.10
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: byebug
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|