lutaml-uml 0.4.1 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (135) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/release.yml +22 -0
  3. data/Gemfile +1 -5
  4. data/README.adoc +4 -42
  5. data/Rakefile +0 -5
  6. data/lutaml-uml.gemspec +23 -38
  7. metadata +20 -292
  8. data/.github/workflows/macos.yml +0 -38
  9. data/.github/workflows/ubuntu.yml +0 -40
  10. data/.github/workflows/windows.yml +0 -51
  11. data/.gitignore +0 -12
  12. data/.rspec +0 -3
  13. data/.travis.yml +0 -6
  14. data/CODE_OF_CONDUCT.md +0 -74
  15. data/LUTAML.adoc +0 -344
  16. data/bin/console +0 -15
  17. data/bin/folder_yaml2lutaml.sh +0 -6
  18. data/bin/plantuml2lutaml +0 -59
  19. data/bin/setup +0 -8
  20. data/bin/yaml2lutaml +0 -144
  21. data/exe/lutaml-wsd2uml +0 -59
  22. data/exe/lutaml-yaml2uml +0 -144
  23. data/lib/lutaml/layout/engine.rb +0 -15
  24. data/lib/lutaml/layout/graph_viz_engine.rb +0 -19
  25. data/lib/lutaml/uml/abstraction.rb +0 -11
  26. data/lib/lutaml/uml/activity.rb +0 -11
  27. data/lib/lutaml/uml/actor.rb +0 -19
  28. data/lib/lutaml/uml/association.rb +0 -41
  29. data/lib/lutaml/uml/behavior.rb +0 -11
  30. data/lib/lutaml/uml/class.rb +0 -83
  31. data/lib/lutaml/uml/classifier.rb +0 -11
  32. data/lib/lutaml/uml/connector.rb +0 -21
  33. data/lib/lutaml/uml/constraint.rb +0 -12
  34. data/lib/lutaml/uml/constructor_end.rb +0 -16
  35. data/lib/lutaml/uml/data_type.rb +0 -75
  36. data/lib/lutaml/uml/dependency.rb +0 -21
  37. data/lib/lutaml/uml/diagram.rb +0 -8
  38. data/lib/lutaml/uml/document.rb +0 -81
  39. data/lib/lutaml/uml/enum.rb +0 -45
  40. data/lib/lutaml/uml/event.rb +0 -12
  41. data/lib/lutaml/uml/final_state.rb +0 -11
  42. data/lib/lutaml/uml/formatter/base.rb +0 -67
  43. data/lib/lutaml/uml/formatter/graphviz.rb +0 -334
  44. data/lib/lutaml/uml/formatter.rb +0 -21
  45. data/lib/lutaml/uml/has_attributes.rb +0 -14
  46. data/lib/lutaml/uml/has_members.rb +0 -30
  47. data/lib/lutaml/uml/instance.rb +0 -17
  48. data/lib/lutaml/uml/model.rb +0 -13
  49. data/lib/lutaml/uml/node/base.rb +0 -21
  50. data/lib/lutaml/uml/node/class_node.rb +0 -57
  51. data/lib/lutaml/uml/node/class_relationship.rb +0 -14
  52. data/lib/lutaml/uml/node/document.rb +0 -18
  53. data/lib/lutaml/uml/node/field.rb +0 -34
  54. data/lib/lutaml/uml/node/has_name.rb +0 -15
  55. data/lib/lutaml/uml/node/has_type.rb +0 -15
  56. data/lib/lutaml/uml/node/method.rb +0 -29
  57. data/lib/lutaml/uml/node/method_argument.rb +0 -16
  58. data/lib/lutaml/uml/node/relationship.rb +0 -28
  59. data/lib/lutaml/uml/opaque_behavior.rb +0 -11
  60. data/lib/lutaml/uml/operation.rb +0 -31
  61. data/lib/lutaml/uml/package.rb +0 -53
  62. data/lib/lutaml/uml/parsers/attribute.rb +0 -70
  63. data/lib/lutaml/uml/parsers/dsl.rb +0 -413
  64. data/lib/lutaml/uml/parsers/dsl_preprocessor.rb +0 -59
  65. data/lib/lutaml/uml/parsers/dsl_transform.rb +0 -27
  66. data/lib/lutaml/uml/parsers/yaml.rb +0 -46
  67. data/lib/lutaml/uml/port.rb +0 -8
  68. data/lib/lutaml/uml/primitive_type.rb +0 -14
  69. data/lib/lutaml/uml/property.rb +0 -27
  70. data/lib/lutaml/uml/pseudostate.rb +0 -11
  71. data/lib/lutaml/uml/realization.rb +0 -11
  72. data/lib/lutaml/uml/region.rb +0 -12
  73. data/lib/lutaml/uml/serializers/association.rb +0 -58
  74. data/lib/lutaml/uml/serializers/base.rb +0 -16
  75. data/lib/lutaml/uml/serializers/class.rb +0 -29
  76. data/lib/lutaml/uml/serializers/top_element_attribute.rb +0 -14
  77. data/lib/lutaml/uml/serializers/yaml_view.rb +0 -18
  78. data/lib/lutaml/uml/state.rb +0 -12
  79. data/lib/lutaml/uml/state_machine.rb +0 -12
  80. data/lib/lutaml/uml/top_element.rb +0 -58
  81. data/lib/lutaml/uml/top_element_attribute.rb +0 -37
  82. data/lib/lutaml/uml/transition.rb +0 -12
  83. data/lib/lutaml/uml/trigger.rb +0 -12
  84. data/lib/lutaml/uml/value.rb +0 -30
  85. data/lib/lutaml/uml/version.rb +0 -7
  86. data/lib/lutaml/uml/vertex.rb +0 -11
  87. data/lib/lutaml/uml.rb +0 -13
  88. data/spec/fixtures/datamodel/models/AddressClassProfile.yml +0 -90
  89. data/spec/fixtures/datamodel/models/AddressComponentProfile.yml +0 -63
  90. data/spec/fixtures/datamodel/models/AddressComponentSpecification.yml +0 -15
  91. data/spec/fixtures/datamodel/models/AddressProfile.yml +0 -36
  92. data/spec/fixtures/datamodel/models/AttributeProfile.yml +0 -32
  93. data/spec/fixtures/datamodel/models/InterchangeAddressClassProfile.yml +0 -79
  94. data/spec/fixtures/datamodel/models/Localization copy.yml +0 -23
  95. data/spec/fixtures/datamodel/models/Localization.yml +0 -23
  96. data/spec/fixtures/datamodel/models/ProfileCompliantAddress.yml +0 -36
  97. data/spec/fixtures/datamodel/models/ProfileCompliantAddressComponent.yml +0 -15
  98. data/spec/fixtures/datamodel/models/Signature.yml +0 -20
  99. data/spec/fixtures/datamodel/models/SignatureBlankDefinition.yml +0 -20
  100. data/spec/fixtures/datamodel/models/TextDirectionCode copy.yml +0 -16
  101. data/spec/fixtures/datamodel/models/TextDirectionCode.yml +0 -16
  102. data/spec/fixtures/datamodel/models/Validity.yml +0 -14
  103. data/spec/fixtures/datamodel/models/iso19160-1/Address.yml +0 -22
  104. data/spec/fixtures/datamodel/models/iso19160-1/AddressComponent.yml +0 -2
  105. data/spec/fixtures/datamodel/style.uml.inc +0 -37
  106. data/spec/fixtures/datamodel/views/AddressClassProfile.yml +0 -12
  107. data/spec/fixtures/datamodel/views/AddressProfile.yml +0 -3
  108. data/spec/fixtures/datamodel/views/CommonModels.yml +0 -9
  109. data/spec/fixtures/datamodel/views/TopDown.yml +0 -62
  110. data/spec/fixtures/dsl/broken_diagram.lutaml +0 -34
  111. data/spec/fixtures/dsl/diagram.lutaml +0 -3
  112. data/spec/fixtures/dsl/diagram_attributes.lutaml +0 -5
  113. data/spec/fixtures/dsl/diagram_blank_definion.lutaml +0 -6
  114. data/spec/fixtures/dsl/diagram_blank_entities.lutaml +0 -8
  115. data/spec/fixtures/dsl/diagram_class_assocation.lutaml +0 -29
  116. data/spec/fixtures/dsl/diagram_class_fields.lutaml +0 -25
  117. data/spec/fixtures/dsl/diagram_commented_includes.lutaml +0 -5
  118. data/spec/fixtures/dsl/diagram_comments.lutaml +0 -28
  119. data/spec/fixtures/dsl/diagram_concept_model.lutaml +0 -132
  120. data/spec/fixtures/dsl/diagram_data_types.lutaml +0 -44
  121. data/spec/fixtures/dsl/diagram_definitions.lutaml +0 -25
  122. data/spec/fixtures/dsl/diagram_includes.lutaml +0 -6
  123. data/spec/fixtures/dsl/diagram_multiply_classes.lutaml +0 -7
  124. data/spec/fixtures/dsl/diagram_non_existing_include.lutaml +0 -6
  125. data/spec/fixtures/dsl/shared.lutaml +0 -3
  126. data/spec/fixtures/dsl/shared1.lutaml +0 -4
  127. data/spec/fixtures/generated_dot/AddressClassProfile.dot +0 -170
  128. data/spec/fixtures/generated_dot/AddressProfile.dot +0 -34
  129. data/spec/lutaml/layout/graph_viz_engine_spec.rb +0 -31
  130. data/spec/lutaml/uml/formatter/graphviz_spec.rb +0 -41
  131. data/spec/lutaml/uml/parsers/dsl_spec.rb +0 -343
  132. data/spec/lutaml/uml/parsers/yaml_spec.rb +0 -18
  133. data/spec/lutaml/uml/serializers/yaml_view_spec.rb +0 -20
  134. data/spec/lutaml/uml_spec.rb +0 -7
  135. data/spec/spec_helper.rb +0 -25
@@ -1,25 +0,0 @@
1
- diagram MyView {
2
- title "my diagram"
3
-
4
- class Component {}
5
-
6
- class AddressClassProfile {
7
- +addressClassProfile: CharacterString [0..1]
8
- }
9
-
10
- class AttributeProfile {
11
- imlicistAttributeProfile: CharacterString [0..1]
12
- +attributeProfile: <<BasicDocument>> LocalizedString [0..1]
13
- +attributeProfile1: <<BasicDocument>> 'LocalizedString'
14
- -privateAttributeProfile: CharacterString [1]
15
- ~friendlyAttributeProfile: <<Type>> "CharacterString" [1..*]
16
- ~friendlyAttributeProfile1: <<Type>> "CharacterString"
17
- #protectedAttributeProfile: CharacterString
18
- type/text: String
19
- slashType: slash/type
20
- application/docbook+xml
21
- application/tei+xml
22
- text/x-asciidoc
23
- application/x-isodoc+xml
24
- }
25
- }
@@ -1,5 +0,0 @@
1
- diagram MyView {
2
- title "my diagram"
3
-
4
- ** include ../models/bipm_document/BipmCommitteeAcronym.lutaml
5
- }
@@ -1,28 +0,0 @@
1
- diagram MyView {
2
- title "my diagram"
3
-
4
- ** My comment
5
-
6
- class Component {}
7
-
8
- *|
9
- this is multiline
10
- comment with {} special
11
- chars/
12
-
13
- +-|/
14
- |*
15
- class AddressClassProfile {
16
- // TODO: write attributes
17
- +addressClassProfile: CharacterString [0..1]
18
- }
19
-
20
- // TODO: description
21
- class AttributeProfile {
22
- ** this is attribute comment
23
- imlicistAttributeProfile: CharacterString [0..1]
24
- *| this is another comment line
25
- with multiply lines
26
- |*
27
- }
28
- }
@@ -1,132 +0,0 @@
1
- diagram Designations {
2
- title 'Designation models'
3
- association {
4
- owner NormativeStatus
5
- member_type direct
6
- member Designation
7
- }
8
- association {
9
- owner PrefixDesignation
10
- member_type inheritance
11
- member ExpressionDesignation
12
- }
13
- association {
14
- owner SuffixDesignation
15
- member_type inheritance
16
- member ExpressionDesignation
17
- }
18
- association {
19
- owner AbbreviationDesignation
20
- member_type inheritance
21
- member ExpressionDesignation
22
- }
23
- association {
24
- owner GrammarInfo
25
- member_type direct
26
- member ExpressionDesignation
27
- }
28
- association {
29
- owner AbbreviationType
30
- member_type direct
31
- member AbbreviationDesignation
32
- }
33
- association {
34
- owner GrammarGender
35
- member_type direct
36
- member GrammarInfo
37
- }
38
- association {
39
- owner GlossaristTextElementType
40
- member_type inheritance
41
- member TextElementType
42
- }
43
- association {
44
- owner GlossaristTextElementType
45
- member_type direct
46
- member ExpressionDesignation
47
- }
48
- association {
49
- owner TextElement
50
- member_type inheritance
51
- member GlossaristTextElement
52
- }
53
- association {
54
- owner EmptySlot
55
- member_type inheritance
56
- member GlossaristTextElement
57
- }
58
- association {
59
- owner GlossaristTextElement
60
- member_type direct
61
- member GlossaristTextElementType
62
- }
63
- class Designation {
64
- +normativeStatus: 'NormativeStatus'
65
- +absent: 'Boolean' [0..1]
66
- +geographicArea: 'Iso3166Code' [0..*]
67
- +sources: 'ConceptSource' [0..*]
68
- }
69
- enum NormativeStatus {
70
- }
71
- class ExpressionDesignation {
72
- +text: 'GlossaristTextElementType'
73
- +language: 'Iso639ThreeCharCode'
74
- +script: 'Iso15924Code' [0..1]
75
- +pronunciation: <<BasicDocument>> 'LocalizedString' [0..*]
76
- +grammarInfo: 'GrammarInfo' [0..*]
77
- }
78
- association {
79
- owner ExpressionDesignation
80
- member_type inheritance
81
- member Designation
82
- }
83
- class GrammarInfo {
84
- +gender: 'GrammarGender' [0..*]
85
- +isPreposition: 'Boolean' [0..1]
86
- +isParticiple: 'Boolean' [0..1]
87
- +isAdjective: 'Boolean' [0..1]
88
- +isVerb: 'Boolean' [0..1]
89
- +isAdverb: 'Boolean' [0..1]
90
- +isNoun: 'Boolean' [0..1]
91
- }
92
- class SymbolDesignation {
93
- +isInternational: 'Boolean'
94
- }
95
- association {
96
- owner SymbolDesignation
97
- member_type inheritance
98
- member Designation
99
- }
100
- class PrefixDesignation {
101
- }
102
- class SuffixDesignation {
103
- }
104
- class AbbreviationDesignation {
105
- +isInternational: 'Boolean'
106
- +abbreviationType: 'AbbreviationType' [0..1]
107
- }
108
- enum AbbreviationType {
109
- }
110
- class LetterSymbolDesignation {
111
- +text: <<BasicDocument>> 'LocalizedString'
112
- +language: 'Iso639ThreeCharCode'
113
- +script: 'Iso15924Code' [0..1]
114
- }
115
- association {
116
- owner LetterSymbolDesignation
117
- member_type inheritance
118
- member SymbolDesignation
119
- }
120
- class GraphicalSymbolDesignation {
121
- +text: <<BasicDocument>> 'LocalizedString' [0..1]
122
- +image: 'Image' [0..1]
123
- +isInternational: 'Boolean'
124
- }
125
- association {
126
- owner GraphicalSymbolDesignation
127
- member_type inheritance
128
- member SymbolDesignation
129
- }
130
- enum GrammarGender {
131
- }
132
- }
@@ -1,44 +0,0 @@
1
- diagram MyView {
2
- title "my diagram"
3
-
4
- enum MyEnum {}
5
-
6
- enum AddressClassProfile <<my_keyword>> {
7
- +addressClassProfile: CharacterString
8
- }
9
-
10
- data_type "Banking Information" {
11
- definition {
12
- Common code types used in banking.
13
- }
14
- "art code" {
15
- definition {
16
- The bank ART code.
17
- }
18
- }
19
- "CCT Number"
20
- }
21
-
22
- data_type DateTimeType {
23
- definition {
24
- Type of date time value.
25
- }
26
- year {
27
- definition {
28
- The value only provides year.
29
- }
30
- }
31
- monthYear
32
- dayMonthYear
33
- }
34
-
35
- primitive Integer
36
-
37
- enum Profile {
38
- imlicistAttributeProfile: CharacterString
39
- +attributeProfile: CharacterString
40
- -privateAttributeProfile: CharacterString
41
- ~friendlyAttributeProfile: CharacterString
42
- #protectedAttributeProfile: CharacterString
43
- }
44
- }
@@ -1,25 +0,0 @@
1
- diagram MyView {
2
- title "my diagram"
3
-
4
- class AddressClassProfile {
5
- definition {
6
- this is multiline with `ascidoc`
7
- comments
8
- and list
9
- \{foo\} \{name\}
10
- }
11
- +addressClassProfile: CharacterString [0..1]
12
- }
13
-
14
- class AttributeProfile {
15
- imlicistAttributeProfile: CharacterString [0..1] {
16
- definition
17
- {
18
- this is attribute definition
19
- with multiply lines
20
- \{foo\} \{name\}
21
- end definition
22
- }
23
- }
24
- }
25
- }
@@ -1,6 +0,0 @@
1
- diagram MyView {
2
- fontname "Arial"
3
- title "my diagram"
4
- include shared.lutaml
5
- include shared1.lutaml
6
- }
@@ -1,7 +0,0 @@
1
- diagram MyView {
2
- title "my diagram"
3
- class Foo {}
4
- class Doo {}
5
- class Koo {}
6
- class NamespacedClass <<MyNamespace>> {}
7
- }
@@ -1,6 +0,0 @@
1
- diagram MyView {
2
- fontname "Arial"
3
- title "my diagram"
4
- include none_existing.lutaml
5
- include none_existing1.lutaml
6
- }
@@ -1,3 +0,0 @@
1
- class Foo {}
2
- class Doo {}
3
- class Koo {}
@@ -1,4 +0,0 @@
1
- class AttributeProfile {
2
- imlicistAttributeProfile: CharacterString [0..1]
3
- +attributeProfile: <<BasicDocument>> LocalizedString [0..1]
4
- }
@@ -1,170 +0,0 @@
1
- digraph G {
2
- graph [splines="ortho" pad=0.5 ranksep="1.2.equally" nodesep="1.2.equally"]
3
- edge [color="gray50"]
4
- node [shape="box" fontname="Helvetica-bold"]
5
-
6
- AddressProfile [
7
- shape="plain"
8
- fontname="Helvetica"
9
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
10
- <TR>
11
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
12
- <TR><TD ALIGN="CENTER"><B>AddressProfile</B></TD></TR>
13
- </TABLE>
14
- </TD>
15
- </TR>
16
-
17
- <TR>
18
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
19
- <TR><TD ALIGN="LEFT"></TD></TR>
20
- </TABLE></TD>
21
- </TR>
22
-
23
- <TR>
24
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
25
- <TR><TD ALIGN="LEFT"></TD></TR>
26
- </TABLE></TD>
27
- </TR>
28
-
29
- </TABLE>>]
30
-
31
- AddressClassProfile [
32
- shape="plain"
33
- fontname="Helvetica"
34
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
35
- <TR>
36
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
37
- <TR><TD ALIGN="CENTER"><B>AddressClassProfile</B></TD></TR>
38
- </TABLE>
39
- </TD>
40
- </TR>
41
-
42
- <TR>
43
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
44
- <TR><TD ALIGN="LEFT"></TD></TR>
45
- </TABLE></TD>
46
- </TR>
47
-
48
- <TR>
49
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
50
- <TR><TD ALIGN="LEFT"></TD></TR>
51
- </TABLE></TD>
52
- </TR>
53
-
54
- </TABLE>>]
55
-
56
- AddressComponentProfile [
57
- shape="plain"
58
- fontname="Helvetica"
59
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
60
- <TR>
61
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
62
- <TR><TD ALIGN="CENTER"><B>AddressComponentProfile</B></TD></TR>
63
- </TABLE>
64
- </TD>
65
- </TR>
66
-
67
- <TR>
68
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
69
- <TR><TD ALIGN="LEFT"></TD></TR>
70
- </TABLE></TD>
71
- </TR>
72
-
73
- <TR>
74
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
75
- <TR><TD ALIGN="LEFT"></TD></TR>
76
- </TABLE></TD>
77
- </TR>
78
-
79
- </TABLE>>]
80
-
81
- AttributeProfile [
82
- shape="plain"
83
- fontname="Helvetica"
84
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
85
- <TR>
86
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
87
- <TR><TD ALIGN="CENTER"><B>AttributeProfile</B></TD></TR>
88
- </TABLE>
89
- </TD>
90
- </TR>
91
-
92
- <TR>
93
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
94
- <TR><TD ALIGN="LEFT"></TD></TR>
95
- </TABLE></TD>
96
- </TR>
97
-
98
- <TR>
99
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
100
- <TR><TD ALIGN="LEFT"></TD></TR>
101
- </TABLE></TD>
102
- </TR>
103
-
104
- </TABLE>>]
105
-
106
- ProfileCompliantAddress [
107
- shape="plain"
108
- fontname="Helvetica"
109
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
110
- <TR>
111
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
112
- <TR><TD ALIGN="CENTER"><B>ProfileCompliantAddress</B></TD></TR>
113
- </TABLE>
114
- </TD>
115
- </TR>
116
-
117
- <TR>
118
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
119
- <TR><TD ALIGN="LEFT"></TD></TR>
120
- </TABLE></TD>
121
- </TR>
122
-
123
- <TR>
124
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
125
- <TR><TD ALIGN="LEFT"></TD></TR>
126
- </TABLE></TD>
127
- </TR>
128
-
129
- </TABLE>>]
130
-
131
- InterchangeAddressClassProfile [
132
- shape="plain"
133
- fontname="Helvetica"
134
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
135
- <TR>
136
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
137
- <TR><TD ALIGN="CENTER"><B>InterchangeAddressClassProfile</B></TD></TR>
138
- </TABLE>
139
- </TD>
140
- </TR>
141
-
142
- <TR>
143
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
144
- <TR><TD ALIGN="LEFT"></TD></TR>
145
- </TABLE></TD>
146
- </TR>
147
-
148
- <TR>
149
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
150
- <TR><TD ALIGN="LEFT"></TD></TR>
151
- </TABLE></TD>
152
- </TR>
153
-
154
- </TABLE>>]
155
-
156
- AddressProfile -> AddressComponentProfile [dir="back" label="defines ▶" arrowtail="onormal" arrowhead="odiamond" taillabel="+componentProfile 0..*"]
157
- AddressProfile -> AddressClassProfile [dir="back" label="defines ▶" arrowtail="onormal" arrowhead="odiamond" taillabel="+addressProfile 0..*"]
158
- AddressClassProfile -> AttributeProfile [dir="both" headlabel="+addressClassProfile" taillabel="+attributeProfile" arrowtail="odiamond" arrowhead="vee"]
159
- AddressClassProfile -> ProfileCompliantAddress [dir="direct" label="◀ compliesWith" headlabel="+profile 1..1" arrowtail="onormal" arrowhead="vee"]
160
- AddressComponentProfile -> AddressClassProfile [dir="direct" label="◀ uses" taillabel="+componentProfile" arrowtail="onormal" arrowhead="odiamond"]
161
- AddressComponentProfile -> AttributeProfile [dir="both" headlabel="+addressClassProfile" taillabel="+attributeProfile" arrowtail="odiamond" arrowhead="vee"]
162
-
163
-
164
-
165
- InterchangeAddressClassProfile -> AddressClassProfile [dir="direct" arrowtail="onormal" arrowhead="onormal"]
166
-
167
-
168
-
169
-
170
- }
@@ -1,34 +0,0 @@
1
- digraph G {
2
- graph [splines="ortho" pad=0.5 ranksep="1.2.equally" nodesep="1.2.equally"]
3
- edge [color="gray50"]
4
- node [shape="box" fontname="Helvetica-bold"]
5
-
6
- AddressProfile [
7
- shape="plain"
8
- fontname="Helvetica"
9
- label=<<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" CELLPADDING="10">
10
- <TR>
11
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
12
- <TR><TD ALIGN="CENTER"><B>AddressProfile</B></TD></TR>
13
- </TABLE>
14
- </TD>
15
- </TR>
16
-
17
- <TR>
18
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
19
- <TR><TD ALIGN="LEFT">+country : iso3166Code&#91;0..*&#93;</TD></TR>
20
- </TABLE>
21
- </TD>
22
- </TR>
23
-
24
- <TR>
25
- <TD><TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0">
26
- <TR><TD ALIGN="LEFT"></TD></TR>
27
- </TABLE></TD>
28
- </TR>
29
-
30
- </TABLE>>]
31
-
32
- AddressProfile -> AddressComponentProfile [dir="back" label="defines ▶" arrowtail="onormal" arrowhead="odiamond" taillabel="+componentProfile 0..*"]
33
- AddressProfile -> AddressClassProfile [dir="back" label="defines ▶" arrowtail="onormal" arrowhead="odiamond" taillabel="+addressProfile 0..*"]
34
- }
@@ -1,31 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "spec_helper"
4
-
5
- RSpec.describe Lutaml::Layout::GraphVizEngine do
6
- describe "#render" do
7
- subject(:render) do
8
- described_class.new(input: input).render(type)
9
- end
10
- let(:input) do
11
- File.read(fixtures_path("generated_dot/AddressClassProfile.dot"))
12
- end
13
-
14
- context "when png output type" do
15
- let(:type) { "png" }
16
- let(:png_header) { "\x89PNG" }
17
-
18
- it "renders input as png binary string" do
19
- expect(render[0..3]).to(eq(png_header))
20
- end
21
- end
22
-
23
- context "when dot output type" do
24
- let(:type) { "dot" }
25
-
26
- it "renders input as dot string" do
27
- expect(render).to(match("digraph G {"))
28
- end
29
- end
30
- end
31
- end
@@ -1,41 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "spec_helper"
4
-
5
- RSpec.describe Lutaml::Uml::Formatter::Graphviz do
6
- describe ".format_document" do
7
- subject(:format_document) do
8
- described_class.new.format_document(input_document)
9
- end
10
-
11
- context "when simple aggregation" do
12
- let(:input_document) do
13
- Lutaml::Uml::Parsers::Yaml
14
- .parse(fixtures_path("datamodel/views/AddressProfile.yml"))
15
- end
16
-
17
- let(:formatted_dot_content) do
18
- File.read(fixtures_path("generated_dot/AddressProfile.dot"))
19
- end
20
-
21
- it "generates the correct relationship graph" do
22
- expect(format_document).to eq(formatted_dot_content)
23
- end
24
- end
25
-
26
- context "when aggregation with inheritance" do
27
- let(:input_document) do
28
- Lutaml::Uml::Parsers::Yaml
29
- .parse(fixtures_path("datamodel/views/AddressClassProfile.yml"))
30
- end
31
-
32
- let(:formatted_dot_content) do
33
- File.read(fixtures_path("generated_dot/AddressClassProfile.dot"))
34
- end
35
-
36
- it "generates the correct relationship graph" do
37
- expect(format_document).to eq(formatted_dot_content)
38
- end
39
- end
40
- end
41
- end