metanorma-plugin-lutaml 0.4.13 → 0.4.14
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/metanorma/plugin/lutaml/liquid_templates/_packages_data_dictionary.liquid +3 -5
- data/lib/metanorma/plugin/lutaml/liquid_templates/_packages_data_dictionary_class.liquid +3 -5
- data/lib/metanorma/plugin/lutaml/liquid_templates/_packages_entity_list.liquid +5 -2
- data/lib/metanorma/plugin/lutaml/liquid_templates/_packages_entity_list_class.liquid +1 -1
- data/lib/metanorma/plugin/lutaml/liquid_templates/_packages_entity_list_classes.liquid +1 -1
- data/lib/metanorma/plugin/lutaml/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d32e2622337e811833b81c4a3be6ff720d5b062807cd1e11532a4178e75a7f50
|
4
|
+
data.tar.gz: d048df682f6c5cc77770d74585b87644cf43d27e4bad65cfad6829fe3c75c2ad
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 51972b3a3ca4fa2701813aefb8425cee81499725e8b488dd99098e446b1b37e8580cad84629e058ddab4ff8bd8db272558cd3f2666316623a9801407bd65ead6
|
7
|
+
data.tar.gz: 198d5703597a8c28a55e0d8c8845bc74738fbb3248fbc376d9c8488836c606f4d4e198bff24c24444d5c019455baa5f72ed970f51ef02f85845d1cc55c63f5a8
|
@@ -135,7 +135,7 @@ None.
|
|
135
135
|
{% assign non_unions = package.data_types | where: "stereotype", "DataType" %}
|
136
136
|
{% if non_unions.size > 0 %}
|
137
137
|
{% for data_type in non_unions %}
|
138
|
-
{% capture generalizations %}{% assign inheritance = klass.associations | where: "member_end_type", "inheritance" %}{% for assoc in inheritance %}{%
|
138
|
+
{% capture generalizations %}{% assign inheritance = klass.associations | where: "member_end_type", "inheritance" %}{% for assoc in inheritance %}{% if additional_context.external_classes[assoc.member_end] %}<<{{ additional_context.external_classes[assoc.member_end] }},{{ assoc.member_end }}>>{% else %}<<section-{{ additional_context.external_classes[assoc.member_end] }},{{ assoc.member_end_xmi_id }}>>{% endif %}{% endfor %}{% endcapture %}
|
139
139
|
[[section-{{ data_type.xmi_id }}]]
|
140
140
|
{{equalsigns}}== {{ data_type.name }}
|
141
141
|
|
@@ -166,8 +166,7 @@ h| Constraint:
|
|
166
166
|
{% if assoc.member_end_attribute_name.size > 0 %}
|
167
167
|
{% capture cardinality %}[{% case assoc.member_end_cardinality.min %}{% when "C" %}0{% when "M" %}1{% else %}{{assoc.member_end_cardinality.min}}{% endcase %}..{{ assoc.member_end_cardinality.max }}]{% endcapture %}
|
168
168
|
| {{ assoc.member_end_attribute_name }}
|
169
|
-
{%
|
170
|
-
| <<{{ ref_id }},{{assoc.member_end}}>> {{ cardinality }}
|
169
|
+
{% if additional_context.external_classes[assoc.member_end] %}| <<{{ additional_context.external_classes[assoc.member_end] }},{{assoc.member_end}}>> {{ cardinality }}{% else %}| <<section-{{ assoc.member_end_xmi_id }},{{assoc.member_end}}>> {{ cardinality }}{% endif %}
|
171
170
|
| {{ assoc.definition | replace: '|', '\|' }}
|
172
171
|
{% endif %}
|
173
172
|
{% endfor %}
|
@@ -196,8 +195,7 @@ h| Constraint:
|
|
196
195
|
{% for attr in data_type.attributes %}
|
197
196
|
{% capture cardinality %}[{% case attr.cardinality.min %}{% when 'C' %}0{% when 'M' %}1{% else %}{{ attr.cardinality.min }}{% endcase %}..{{ attr.cardinality.max }}]{% endcapture %}
|
198
197
|
| {{ attr.name }}
|
199
|
-
{%
|
200
|
-
| <<{{ ref_id }},{{ attr.type }}>> {{ cardinality }}
|
198
|
+
{% if additional_context.external_classes[attr.type] %}| <<{{ additional_context.external_classes[attr.type] }},{{ attr.type }}>> {{ cardinality }}{% else %}| <<section-{{ attr.xmi_id }},{{ attr.type }}>> {{ cardinality }}{% endif %}
|
201
199
|
| {{ attr.definition | replace: '|', '\|' }}
|
202
200
|
|
203
201
|
{% endfor %}
|
@@ -1,5 +1,5 @@
|
|
1
1
|
{% capture equalsigns %}{% for count in (1..depth) %}={% endfor %}{% endcapture %}
|
2
|
-
{% capture generalizations %}{% assign inheritance = klass.associations | where: "member_end_type", "inheritance" %}{% for assoc in inheritance %}{%
|
2
|
+
{% capture generalizations %}{% assign inheritance = klass.associations | where: "member_end_type", "inheritance" %}{% for assoc in inheritance %}{% if additional_context.external_classes[assoc.member_end] %}<<{{ additional_context.external_classes[assoc.member_end] }},{{ assoc.member_end }}>>{% else %}<<section-{{ assoc.member_end_xmi_id }},{{ assoc.member_end }}>>{% endif %}{% endfor %}{% endcapture %}
|
3
3
|
[[section-{{ klass.xmi_id }}]]
|
4
4
|
{{equalsigns}} {{ klass.name }}
|
5
5
|
{%comment%}(inside class: depth is {{ depth }}, equalsigns {{equalsigns}}){%endcomment%}
|
@@ -31,8 +31,7 @@ h| Constraint:
|
|
31
31
|
{% if assoc.member_end_attribute_name.size > 0 %}
|
32
32
|
{% capture cardinality %}[{% case assoc.member_end_cardinality.min %}{% when "C" %}0{% when "M" %}1{% else %}{{assoc.member_end_cardinality.min}}{% endcase %}..{{ assoc.member_end_cardinality.max }}]{% endcapture %}
|
33
33
|
| {{ assoc.member_end_attribute_name }}
|
34
|
-
{%
|
35
|
-
| <<{{ ref_id }},{{assoc.member_end}}>> {{ cardinality }}
|
34
|
+
{% if additional_context.external_classes[assoc.member_end] %}| <<{{ additional_context.external_classes[assoc.member_end] }},{{assoc.member_end}}>> {{ cardinality }}{% else %}| <<section-{{ assoc.member_end_xmi_id }},{{ assoc.member_end }}>> {{ cardinality }}{% endif %}
|
36
35
|
| {{ assoc.definition | replace: '|', '\|' }}
|
37
36
|
{% endif %}
|
38
37
|
{% endfor %}
|
@@ -60,8 +59,7 @@ h| Constraint:
|
|
60
59
|
{% for attr in klass.attributes %}
|
61
60
|
{% capture cardinality %}[{% case attr.cardinality.min %}{% when 'C' %}0{% when 'M' %}1{% else %}{{ attr.cardinality.min }}{% endcase %}..{{ attr.cardinality.max }}]{% endcapture %}
|
62
61
|
| {{ attr.name }}
|
63
|
-
{%
|
64
|
-
| <<{{ ref_id }},{{ attr.type }}>> {{ cardinality }}
|
62
|
+
{% if additional_context.external_classes[attr.type] %}| <<{{ additional_context.external_classes[attr.type] }},{{ attr.type }}>> {{ cardinality }}{% else %}| <<section-{{ attr.xmi_id }},{{ attr.type }}>> {{ cardinality }}{% endif %}
|
65
63
|
| {{ attr.definition | replace: '|', '\|' }}
|
66
64
|
|
67
65
|
{% endfor %}
|
@@ -89,8 +89,11 @@
|
|
89
89
|
|
90
90
|
{% for klass in package.classes %}
|
91
91
|
{% unless not_classes_stereotypes contains klass.stereotype %}
|
92
|
-
{%
|
93
|
-
| <<{{
|
92
|
+
{% if additional_context.external_classes[klass.name] %}
|
93
|
+
| <<{{ additional_context.external_classes[klass.name] }},{{ klass.name }}>> «{{ klass.stereotype }}»
|
94
|
+
{% else %}
|
95
|
+
| | <<section-{{ klass.xmi_id }},{{ klass.name }}>> «{{ klass.stereotype }}»
|
96
|
+
{% endif %}
|
94
97
|
| {{ klass.definition | replace: '|', '\|' }}
|
95
98
|
|
96
99
|
{% endunless %}
|
@@ -9,7 +9,7 @@
|
|
9
9
|
{% assign package_name = package.name %}
|
10
10
|
{% unless package_entities and package_entities[package_name][klass_name] != true %}
|
11
11
|
{% unless not_classes_stereotypes contains klass.stereotype %}
|
12
|
-
| <<{{ klass.
|
12
|
+
| <<section-{{ klass.xmi_id }},{{ klass.name }}>> «{{ klass.stereotype }}»
|
13
13
|
| {{ klass.definition | replace: '|', '\|' }}
|
14
14
|
|
15
15
|
{% endunless %}
|
@@ -4,7 +4,7 @@
|
|
4
4
|
|Name |Description
|
5
5
|
|
6
6
|
{% for klass in classes %}
|
7
|
-
| <<{{ klass.
|
7
|
+
| <<section-{{ klass.xmi_id }},{{ klass.name }}>> «{{ klass.stereotype | default: "Enumeration" }}»
|
8
8
|
| {{ klass.definition | replace: '|', '\|' }}
|
9
9
|
|
10
10
|
{% endfor %}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metanorma-plugin-lutaml
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ribose Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-11-
|
11
|
+
date: 2021-11-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: liquid
|
@@ -301,7 +301,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
301
301
|
- !ruby/object:Gem::Version
|
302
302
|
version: '0'
|
303
303
|
requirements: []
|
304
|
-
rubygems_version: 3.
|
304
|
+
rubygems_version: 3.2.22
|
305
305
|
signing_key:
|
306
306
|
specification_version: 4
|
307
307
|
summary: Metanorma plugin for LutaML
|