archimate 1.2.1 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +47 -0
- data/TODOs.org +219 -0
- data/archimate.gemspec +2 -1
- data/exe/archidiff +7 -0
- data/exe/archidiff-summary +7 -0
- data/exe/archimerge +7 -0
- data/exe/fmtxml +7 -0
- data/lib/archimate.rb +10 -21
- data/lib/archimate/cli/archi.rb +2 -1
- data/lib/archimate/cli/cleanup.rb +8 -9
- data/lib/archimate/cli/convert.rb +3 -1
- data/lib/archimate/cli/mapper.rb +1 -1
- data/lib/archimate/cli/stats.rb +1 -1
- data/lib/archimate/config.rb +4 -1
- data/lib/archimate/data_model.rb +11 -24
- data/lib/archimate/data_model/any_attribute.rb +18 -5
- data/lib/archimate/data_model/any_element.rb +30 -7
- data/lib/archimate/data_model/bounds.rb +34 -7
- data/lib/archimate/data_model/color.rb +32 -7
- data/lib/archimate/data_model/comparison.rb +87 -0
- data/lib/archimate/data_model/concern.rb +20 -7
- data/lib/archimate/data_model/connection.rb +71 -51
- data/lib/archimate/data_model/connector_type.rb +23 -0
- data/lib/archimate/data_model/diagram.rb +72 -10
- data/lib/archimate/data_model/diagram_type.rb +17 -0
- data/lib/archimate/data_model/differentiable.rb +142 -0
- data/lib/archimate/data_model/element.rb +39 -45
- data/lib/archimate/data_model/element_type.rb +89 -0
- data/lib/archimate/data_model/font.rb +30 -12
- data/lib/archimate/data_model/lang_string.rb +89 -16
- data/lib/archimate/data_model/layer.rb +55 -0
- data/lib/archimate/data_model/layers.rb +62 -0
- data/lib/archimate/data_model/location.rb +27 -11
- data/lib/archimate/data_model/metadata.rb +10 -3
- data/lib/archimate/data_model/model.rb +188 -121
- data/lib/archimate/data_model/modeling_note.rb +14 -3
- data/lib/archimate/data_model/organization.rb +44 -13
- data/lib/archimate/data_model/{documentation.rb → preserved_lang_string.rb} +1 -5
- data/lib/archimate/data_model/property.rb +17 -11
- data/lib/archimate/data_model/property_definition.rb +34 -4
- data/lib/archimate/data_model/referenceable.rb +0 -9
- data/lib/archimate/data_model/referenceable_collection.rb +201 -0
- data/lib/archimate/data_model/relationship.rb +52 -33
- data/lib/archimate/data_model/relationship_type.rb +43 -0
- data/lib/archimate/data_model/schema_info.rb +17 -6
- data/lib/archimate/data_model/style.rb +41 -11
- data/lib/archimate/data_model/view_node.rb +153 -59
- data/lib/archimate/data_model/viewpoint.rb +56 -80
- data/lib/archimate/data_model/viewpoint_type.rb +429 -0
- data/lib/archimate/export/csv_export.rb +2 -2
- data/lib/archimate/export/cypher.rb +2 -2
- data/lib/archimate/export/graph_ml.rb +7 -5
- data/lib/archimate/export/jsonl.rb +166 -0
- data/lib/archimate/export/n_quads.rb +8 -5
- data/lib/archimate/file_format.rb +4 -5
- data/lib/archimate/file_formats/archi_file_reader.rb +7 -240
- data/lib/archimate/file_formats/archi_file_writer.rb +16 -188
- data/lib/archimate/file_formats/model_exchange_file_reader.rb +7 -225
- data/lib/archimate/file_formats/model_exchange_file_writer_21.rb +22 -114
- data/lib/archimate/file_formats/model_exchange_file_writer_30.rb +22 -122
- data/lib/archimate/file_formats/sax.rb +55 -0
- data/lib/archimate/file_formats/sax/any_element.rb +64 -0
- data/lib/archimate/file_formats/sax/archi/archi_handler_factory.rb +48 -0
- data/lib/archimate/file_formats/sax/archi/bounds.rb +25 -0
- data/lib/archimate/file_formats/sax/archi/connection.rb +47 -0
- data/lib/archimate/file_formats/sax/archi/content.rb +28 -0
- data/lib/archimate/file_formats/sax/archi/diagram.rb +66 -0
- data/lib/archimate/file_formats/sax/archi/element.rb +36 -0
- data/lib/archimate/file_formats/sax/archi/location.rb +25 -0
- data/lib/archimate/file_formats/sax/archi/model.rb +109 -0
- data/lib/archimate/file_formats/sax/archi/organization.rb +60 -0
- data/lib/archimate/file_formats/sax/archi/property.rb +54 -0
- data/lib/archimate/file_formats/sax/archi/relationship.rb +50 -0
- data/lib/archimate/file_formats/sax/archi/style.rb +35 -0
- data/lib/archimate/file_formats/sax/archi/view_node.rb +76 -0
- data/lib/archimate/file_formats/sax/capture_content.rb +20 -0
- data/lib/archimate/file_formats/sax/capture_documentation.rb +19 -0
- data/lib/archimate/file_formats/sax/capture_properties.rb +20 -0
- data/lib/archimate/file_formats/sax/content_element.rb +19 -0
- data/lib/archimate/file_formats/sax/document.rb +80 -0
- data/lib/archimate/file_formats/sax/handler.rb +54 -0
- data/lib/archimate/file_formats/sax/lang_string.rb +28 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/color.rb +36 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/connection.rb +67 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/diagram.rb +60 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/element.rb +43 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/font.rb +44 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/item.rb +64 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/location.rb +23 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/metadata.rb +66 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/model.rb +124 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/model_exchange_handler_factory.rb +53 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/property.rb +32 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/property_definition.rb +36 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/relationship.rb +49 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/schema_info.rb +47 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/style.rb +66 -0
- data/lib/archimate/file_formats/sax/model_exchange_file/view_node.rb +86 -0
- data/lib/archimate/file_formats/sax/no_op.rb +17 -0
- data/lib/archimate/file_formats/sax/preserved_lang_string.rb +28 -0
- data/lib/archimate/file_formats/serializer.rb +57 -0
- data/lib/archimate/file_formats/serializer/archi/bounds.rb +23 -0
- data/lib/archimate/file_formats/serializer/archi/connection.rb +33 -0
- data/lib/archimate/file_formats/serializer/archi/diagram.rb +28 -0
- data/lib/archimate/file_formats/serializer/archi/documentation.rb +16 -0
- data/lib/archimate/file_formats/serializer/archi/element.rb +24 -0
- data/lib/archimate/file_formats/serializer/archi/location.rb +26 -0
- data/lib/archimate/file_formats/serializer/archi/model.rb +25 -0
- data/lib/archimate/file_formats/serializer/archi/organization.rb +21 -0
- data/lib/archimate/file_formats/serializer/archi/property.rb +15 -0
- data/lib/archimate/file_formats/serializer/archi/relationship.rb +36 -0
- data/lib/archimate/file_formats/serializer/archi/view_node.rb +52 -0
- data/lib/archimate/file_formats/serializer/archi/viewpoint_type.rb +45 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/element.rb +25 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/location.rb +15 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/model_exchange_file_writer.rb +32 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/organization.rb +23 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/properties.rb +15 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/relationship.rb +19 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/style.rb +48 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/connection.rb +25 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/diagram.rb +27 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/item.rb +17 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/label.rb +17 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/model.rb +36 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/organization_body.rb +25 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/property.rb +19 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v21/view_node.rb +44 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/connection.rb +26 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/diagram.rb +27 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/item.rb +17 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/label.rb +17 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/model.rb +41 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/organization_body.rb +25 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/property.rb +19 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/property_definitions.rb +34 -0
- data/lib/archimate/file_formats/serializer/model_exchange_file/v30/view_node.rb +45 -0
- data/lib/archimate/file_formats/serializer/named_collection.rb +21 -0
- data/lib/archimate/file_formats/serializer/writer.rb +56 -0
- data/lib/archimate/file_formats/serializer/xml_lang_string.rb +30 -0
- data/lib/archimate/file_formats/serializer/xml_metadata.rb +64 -0
- data/lib/archimate/file_formats/{model_exchange_file → serializer}/xml_property_defs.rb +2 -2
- data/lib/archimate/lint/duplicate_entities.rb +3 -3
- data/lib/archimate/lint/linter.rb +24 -29
- data/lib/archimate/svg/connection.rb +13 -103
- data/lib/archimate/svg/diagram.rb +1 -1
- data/lib/archimate/svg/entity/base_entity.rb +12 -8
- data/lib/archimate/svg/entity/data_entity.rb +2 -2
- data/lib/archimate/svg/entity/diagram_model_reference.rb +1 -1
- data/lib/archimate/svg/entity/event_entity.rb +2 -2
- data/lib/archimate/svg/entity/gap.rb +1 -1
- data/lib/archimate/svg/entity/group.rb +1 -1
- data/lib/archimate/svg/entity/motivation_entity.rb +1 -1
- data/lib/archimate/svg/entity/node.rb +1 -1
- data/lib/archimate/svg/entity/rect_entity.rb +1 -1
- data/lib/archimate/svg/entity/rounded_rect_entity.rb +1 -1
- data/lib/archimate/svg/entity/service_entity.rb +2 -2
- data/lib/archimate/svg/entity/value.rb +2 -2
- data/lib/archimate/svg/path.rb +153 -0
- data/lib/archimate/svg/point.rb +8 -1
- data/lib/archimate/version.rb +1 -1
- metadata +118 -36
- data/lib/archimate/data_model/archimate_node.rb +0 -181
- data/lib/archimate/data_model/concept.rb +0 -14
- data/lib/archimate/data_model/constants.rb +0 -82
- data/lib/archimate/data_model/container.rb +0 -17
- data/lib/archimate/data_model/diffable_array.rb +0 -213
- data/lib/archimate/data_model/diffable_primitive.rb +0 -83
- data/lib/archimate/data_model/label.rb +0 -19
- data/lib/archimate/data_model/named_referenceable.rb +0 -14
- data/lib/archimate/data_model/view.rb +0 -12
- data/lib/archimate/data_model/view_concept.rb +0 -18
- data/lib/archimate/file_formats/archi_file_format.rb +0 -151
- data/lib/archimate/file_formats/archimate_v2.rb +0 -461
- data/lib/archimate/file_formats/model_exchange_file/xml_lang_string.rb +0 -35
- data/lib/archimate/file_formats/model_exchange_file/xml_metadata.rb +0 -115
- data/lib/archimate/file_formats/model_exchange_file/xml_property_definitions.rb +0 -28
- data/lib/archimate/file_formats/model_exchange_file_reader_21.rb +0 -73
- data/lib/archimate/file_formats/model_exchange_file_reader_30.rb +0 -134
- data/lib/archimate/file_formats/model_exchange_file_writer.rb +0 -157
- data/lib/archimate/file_formats/writer.rb +0 -56
@@ -0,0 +1,429 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require "ruby-enum"
|
4
|
+
|
5
|
+
module Archimate
|
6
|
+
module DataModel
|
7
|
+
class ViewpointType
|
8
|
+
include Ruby::Enum
|
9
|
+
|
10
|
+
ENTITIES = DataModel::Layers.values.flat_map(&:elements)
|
11
|
+
|
12
|
+
CORE_ELEMENTS = [DataModel::Layers::Business, DataModel::Layers::Application, DataModel::Layers::Technology]
|
13
|
+
.flat_map(&:elements)
|
14
|
+
|
15
|
+
DEFAULT_RELATIONS = %w[
|
16
|
+
AccessRelationship
|
17
|
+
AggregationRelationship
|
18
|
+
AssignmentRelationship
|
19
|
+
AssociationRelationship
|
20
|
+
CompositionRelationship
|
21
|
+
FlowRelationship
|
22
|
+
RealisationRelationship
|
23
|
+
SpecialisationRelationship
|
24
|
+
TriggeringRelationship
|
25
|
+
UsedByRelationship
|
26
|
+
].freeze
|
27
|
+
|
28
|
+
ViewpointTypeVal = Struct.new(:name, :entities, :relations) do
|
29
|
+
def to_s
|
30
|
+
name
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
# Basic Viewpoints
|
35
|
+
define :Introductory, ViewpointTypeVal.new("Introductory",
|
36
|
+
CORE_ELEMENTS,
|
37
|
+
DataModel::RelationshipType.values)
|
38
|
+
|
39
|
+
# Category:Composition Viewpoints that defines internal compositions and aggregations of elements.
|
40
|
+
define :Organization, ViewpointTypeVal.new("Organization",
|
41
|
+
DataModel::ConnectorType.values + %w[
|
42
|
+
BusinessActor
|
43
|
+
BusinessCollaboration
|
44
|
+
BusinessInterface
|
45
|
+
BusinessRole
|
46
|
+
Location
|
47
|
+
],
|
48
|
+
DEFAULT_RELATIONS - %w[AccessRelationship RealisationRelationship])
|
49
|
+
|
50
|
+
define :Application_platform, ViewpointTypeVal.new("Application Platform",
|
51
|
+
CORE_ELEMENTS,
|
52
|
+
DataModel::RelationshipType.values)
|
53
|
+
|
54
|
+
define :Information_structure, ViewpointTypeVal.new("Information Structure",
|
55
|
+
DataModel::ConnectorType.values + %w[
|
56
|
+
Artifact
|
57
|
+
BusinessObject
|
58
|
+
DataObject
|
59
|
+
Meaning
|
60
|
+
Representation
|
61
|
+
],
|
62
|
+
DEFAULT_RELATIONS - %w[AssignmentRelationship UsedByRelationship])
|
63
|
+
|
64
|
+
define :Technology, ViewpointTypeVal.new("Technology",
|
65
|
+
CORE_ELEMENTS,
|
66
|
+
DataModel::RelationshipType.values)
|
67
|
+
|
68
|
+
define :Layered, ViewpointTypeVal.new("Layered",
|
69
|
+
ENTITIES + DataModel::ConnectorType.values,
|
70
|
+
DataModel::RelationshipType.values)
|
71
|
+
|
72
|
+
define :Physical, ViewpointTypeVal.new("Physical",
|
73
|
+
CORE_ELEMENTS,
|
74
|
+
DataModel::RelationshipType.values)
|
75
|
+
|
76
|
+
# Category:Support Viewpoints where you are looking at elements that are supported by other elements. Typically from one layer and upwards to an above layer.
|
77
|
+
define :Product, ViewpointTypeVal.new("Product",
|
78
|
+
DataModel::ConnectorType.values + %w[
|
79
|
+
ApplicationComponent
|
80
|
+
ApplicationInterface
|
81
|
+
ApplicationService
|
82
|
+
BusinessActor
|
83
|
+
BusinessEvent
|
84
|
+
BusinessFunction
|
85
|
+
BusinessInteraction
|
86
|
+
BusinessInterface
|
87
|
+
BusinessProcess
|
88
|
+
BusinessRole
|
89
|
+
BusinessService
|
90
|
+
Contract
|
91
|
+
Product
|
92
|
+
Value
|
93
|
+
],
|
94
|
+
DEFAULT_RELATIONS)
|
95
|
+
|
96
|
+
define :Application_usage, ViewpointTypeVal.new("Application Usage",
|
97
|
+
DataModel::ConnectorType.values + %w[
|
98
|
+
ApplicationCollaboration
|
99
|
+
ApplicationComponent
|
100
|
+
ApplicationInterface
|
101
|
+
ApplicationService
|
102
|
+
BusinessEvent
|
103
|
+
BusinessFunction
|
104
|
+
BusinessInteraction
|
105
|
+
BusinessObject
|
106
|
+
BusinessProcess
|
107
|
+
BusinessRole
|
108
|
+
DataObject
|
109
|
+
],
|
110
|
+
DEFAULT_RELATIONS)
|
111
|
+
|
112
|
+
define :Technology_usage, ViewpointTypeVal.new("Technology Usage",
|
113
|
+
CORE_ELEMENTS,
|
114
|
+
DataModel::RelationshipType.values)
|
115
|
+
|
116
|
+
# Category:Cooperation Towards peer elements which cooperate with each other. Typically across aspects.
|
117
|
+
define :Business_process_cooperation, ViewpointTypeVal.new("Business Process Cooperation",
|
118
|
+
DataModel::ConnectorType.values + %w[
|
119
|
+
ApplicationService
|
120
|
+
BusinessActor
|
121
|
+
BusinessCollaboration
|
122
|
+
BusinessEvent
|
123
|
+
BusinessFunction
|
124
|
+
BusinessInteraction
|
125
|
+
BusinessObject
|
126
|
+
BusinessProcess
|
127
|
+
BusinessRole
|
128
|
+
BusinessService
|
129
|
+
Location
|
130
|
+
Representation
|
131
|
+
],
|
132
|
+
DEFAULT_RELATIONS)
|
133
|
+
|
134
|
+
define :Application_cooperation, ViewpointTypeVal.new("Application Cooperation",
|
135
|
+
DataModel::ConnectorType.values + %w[
|
136
|
+
ApplicationCollaboration
|
137
|
+
ApplicationComponent
|
138
|
+
ApplicationFunction
|
139
|
+
ApplicationInteraction
|
140
|
+
ApplicationInterface
|
141
|
+
ApplicationService
|
142
|
+
DataObject
|
143
|
+
Location
|
144
|
+
],
|
145
|
+
DEFAULT_RELATIONS)
|
146
|
+
|
147
|
+
# Category:Realization Viewpoints where you are looking at elements that realize other elements. Typically from one layer and downwards to a below layer.
|
148
|
+
define :Service_realization, ViewpointTypeVal.new("Service Realization",
|
149
|
+
DataModel::ConnectorType.values + %w[
|
150
|
+
ApplicationCollaboration
|
151
|
+
ApplicationComponent
|
152
|
+
ApplicationService
|
153
|
+
BusinessActor
|
154
|
+
BusinessCollaboration
|
155
|
+
BusinessEvent
|
156
|
+
BusinessFunction
|
157
|
+
BusinessInteraction
|
158
|
+
BusinessObject
|
159
|
+
BusinessProcess
|
160
|
+
BusinessRole
|
161
|
+
BusinessService
|
162
|
+
DataObject
|
163
|
+
],
|
164
|
+
DEFAULT_RELATIONS)
|
165
|
+
|
166
|
+
define :Implementation_and_deployment, ViewpointTypeVal.new("Implementation and Deployment",
|
167
|
+
DataModel::ConnectorType.values + %w[
|
168
|
+
ApplicationCollaboration
|
169
|
+
ApplicationComponent
|
170
|
+
Artifact
|
171
|
+
CommunicationPath
|
172
|
+
DataObject
|
173
|
+
Device
|
174
|
+
InfrastructureService
|
175
|
+
Network
|
176
|
+
Node
|
177
|
+
SystemSoftware
|
178
|
+
],
|
179
|
+
DEFAULT_RELATIONS)
|
180
|
+
|
181
|
+
define :Goal_realization, ViewpointTypeVal.new("Goal Realization",
|
182
|
+
%w[
|
183
|
+
Constraint
|
184
|
+
Goal
|
185
|
+
Principle
|
186
|
+
Requirement
|
187
|
+
],
|
188
|
+
%w[
|
189
|
+
AggregationRelationship
|
190
|
+
AssociationRelationship
|
191
|
+
CompositionRelationship
|
192
|
+
InfluenceRelationship
|
193
|
+
RealisationRelationship
|
194
|
+
SpecialisationRelationship
|
195
|
+
])
|
196
|
+
|
197
|
+
define :Goal_contribution, ViewpointTypeVal.new("Goal Contribution",
|
198
|
+
%w[
|
199
|
+
Constraint
|
200
|
+
Goal
|
201
|
+
Principle
|
202
|
+
Requirement
|
203
|
+
],
|
204
|
+
%w[
|
205
|
+
AggregationRelationship
|
206
|
+
AssociationRelationship
|
207
|
+
CompositionRelationship
|
208
|
+
InfluenceRelationship
|
209
|
+
RealisationRelationship
|
210
|
+
SpecialisationRelationship
|
211
|
+
])
|
212
|
+
|
213
|
+
define :Principles, ViewpointTypeVal.new("Principles",
|
214
|
+
%w[
|
215
|
+
Goal
|
216
|
+
Principle
|
217
|
+
],
|
218
|
+
%w[
|
219
|
+
AggregationRelationship
|
220
|
+
AssociationRelationship
|
221
|
+
CompositionRelationship
|
222
|
+
InfluenceRelationship
|
223
|
+
RealisationRelationship
|
224
|
+
SpecialisationRelationship
|
225
|
+
])
|
226
|
+
|
227
|
+
define :Requirements_realization, ViewpointTypeVal.new("Requirements Realization",
|
228
|
+
CORE_ELEMENTS + DataModel::ConnectorType.values + %w[
|
229
|
+
Constraint
|
230
|
+
Goal
|
231
|
+
Requirement
|
232
|
+
],
|
233
|
+
DEFAULT_RELATIONS)
|
234
|
+
|
235
|
+
define :Motivation, ViewpointTypeVal.new("Motivation",
|
236
|
+
%w[
|
237
|
+
Assessment
|
238
|
+
Constraint
|
239
|
+
Driver
|
240
|
+
Goal
|
241
|
+
Principle
|
242
|
+
Requirement
|
243
|
+
Stakeholder
|
244
|
+
],
|
245
|
+
%w[
|
246
|
+
AggregationRelationship
|
247
|
+
AssociationRelationship
|
248
|
+
CompositionRelationship
|
249
|
+
FlowRelationship
|
250
|
+
InfluenceRelationship
|
251
|
+
RealisationRelationship
|
252
|
+
SpecialisationRelationship
|
253
|
+
])
|
254
|
+
|
255
|
+
# Strategy Viewpoints
|
256
|
+
define :Strategy, ViewpointTypeVal.new("Strategy",
|
257
|
+
CORE_ELEMENTS,
|
258
|
+
DataModel::RelationshipType.values)
|
259
|
+
|
260
|
+
define :Capability_map, ViewpointTypeVal.new("Capability Map",
|
261
|
+
CORE_ELEMENTS,
|
262
|
+
DataModel::RelationshipType.values)
|
263
|
+
|
264
|
+
define :Outcome_realization, ViewpointTypeVal.new("Outcome Realization",
|
265
|
+
CORE_ELEMENTS,
|
266
|
+
DataModel::RelationshipType.values)
|
267
|
+
|
268
|
+
define :Resource_map, ViewpointTypeVal.new("Resource Map",
|
269
|
+
CORE_ELEMENTS,
|
270
|
+
DataModel::RelationshipType.values)
|
271
|
+
|
272
|
+
# Implementation and Migration Viewpoints
|
273
|
+
define :Project, ViewpointTypeVal.new("Project",
|
274
|
+
DataModel::ConnectorType.values + %w[
|
275
|
+
BusinessActor
|
276
|
+
BusinessRole
|
277
|
+
Deliverable
|
278
|
+
Goal
|
279
|
+
WorkPackage
|
280
|
+
],
|
281
|
+
DEFAULT_RELATIONS - %w[AccessRelationship])
|
282
|
+
|
283
|
+
define :Migration, ViewpointTypeVal.new("Migration",
|
284
|
+
DataModel::ConnectorType.values + %w[Gap Plateau],
|
285
|
+
%w[
|
286
|
+
AndJunction
|
287
|
+
AssociationRelationship
|
288
|
+
CompositionRelationship
|
289
|
+
FlowRelationship
|
290
|
+
Junction
|
291
|
+
OrJunction
|
292
|
+
TriggeringRelationship
|
293
|
+
])
|
294
|
+
|
295
|
+
define :Implementation_and_migration, ViewpointTypeVal.new("Implementation and Migration",
|
296
|
+
CORE_ELEMENTS + DataModel::ConnectorType.values + %w[
|
297
|
+
Location
|
298
|
+
Requirement
|
299
|
+
Constraint
|
300
|
+
Goal
|
301
|
+
BusinessRole
|
302
|
+
WorkPackage
|
303
|
+
Deliverable
|
304
|
+
BusinessActor
|
305
|
+
Plateau
|
306
|
+
Gap
|
307
|
+
],
|
308
|
+
DEFAULT_RELATIONS)
|
309
|
+
|
310
|
+
# Other Viewpoints
|
311
|
+
define :Stakeholder, ViewpointTypeVal.new("Stakeholder",
|
312
|
+
%w[
|
313
|
+
Assessment
|
314
|
+
Driver
|
315
|
+
Goal
|
316
|
+
Stakeholder
|
317
|
+
],
|
318
|
+
%w[
|
319
|
+
AggregationRelationship
|
320
|
+
AssociationRelationship
|
321
|
+
CompositionRelationship
|
322
|
+
InfluenceRelationship
|
323
|
+
SpecialisationRelationship
|
324
|
+
])
|
325
|
+
|
326
|
+
# Other older viewpoints
|
327
|
+
define :Actor_cooperation, ViewpointTypeVal.new("Actor Co-operation",
|
328
|
+
DataModel::ConnectorType.values + %w[
|
329
|
+
ApplicationComponent
|
330
|
+
ApplicationInterface
|
331
|
+
ApplicationService
|
332
|
+
BusinessActor
|
333
|
+
BusinessCollaboration
|
334
|
+
BusinessInterface
|
335
|
+
BusinessRole
|
336
|
+
BusinessService
|
337
|
+
],
|
338
|
+
DEFAULT_RELATIONS - %w[AccessRelationship])
|
339
|
+
|
340
|
+
define :Business_function, ViewpointTypeVal.new("Business Function",
|
341
|
+
DataModel::ConnectorType.values + %w[
|
342
|
+
BusinessActor
|
343
|
+
BusinessFunction
|
344
|
+
BusinessRole
|
345
|
+
],
|
346
|
+
DEFAULT_RELATIONS - %w[AccessRelationship RealisationRelationship])
|
347
|
+
|
348
|
+
define :Business_process, ViewpointTypeVal.new("Business Process",
|
349
|
+
DataModel::ConnectorType.values + %w[
|
350
|
+
ApplicationService
|
351
|
+
BusinessActor
|
352
|
+
BusinessCollaboration
|
353
|
+
BusinessEvent
|
354
|
+
BusinessFunction
|
355
|
+
BusinessInteraction
|
356
|
+
BusinessObject
|
357
|
+
BusinessProcess
|
358
|
+
BusinessRole
|
359
|
+
BusinessService
|
360
|
+
Location
|
361
|
+
Representation
|
362
|
+
],
|
363
|
+
DEFAULT_RELATIONS)
|
364
|
+
|
365
|
+
define :Application_behavior, ViewpointTypeVal.new("Application Behavior",
|
366
|
+
DataModel::ConnectorType.values + %w[
|
367
|
+
ApplicationCollaboration
|
368
|
+
ApplicationComponent
|
369
|
+
ApplicationFunction
|
370
|
+
ApplicationInteraction
|
371
|
+
ApplicationInterface
|
372
|
+
ApplicationService
|
373
|
+
DataObject
|
374
|
+
],
|
375
|
+
DEFAULT_RELATIONS)
|
376
|
+
|
377
|
+
define :Application_structure, ViewpointTypeVal.new("Application Structure",
|
378
|
+
DataModel::ConnectorType.values + %w[
|
379
|
+
ApplicationCollaboration
|
380
|
+
ApplicationComponent
|
381
|
+
ApplicationInterface
|
382
|
+
DataObject
|
383
|
+
],
|
384
|
+
DEFAULT_RELATIONS - %w[RealisationRelationship])
|
385
|
+
|
386
|
+
define :Infrastructure, ViewpointTypeVal.new("Infrastructure",
|
387
|
+
DataModel::ConnectorType.values + %w[
|
388
|
+
Artifact
|
389
|
+
CommunicationPath
|
390
|
+
Device
|
391
|
+
InfrastructureFunction
|
392
|
+
InfrastructureInterface
|
393
|
+
InfrastructureService
|
394
|
+
Location
|
395
|
+
Network
|
396
|
+
Node
|
397
|
+
SystemSoftware
|
398
|
+
],
|
399
|
+
DEFAULT_RELATIONS)
|
400
|
+
|
401
|
+
define :Infrastructure_usage, ViewpointTypeVal.new("Infrastructure Usage",
|
402
|
+
DataModel::ConnectorType.values + %w[
|
403
|
+
ApplicationComponent
|
404
|
+
ApplicationFunction
|
405
|
+
CommunicationPath
|
406
|
+
Device
|
407
|
+
InfrastructureFunction
|
408
|
+
InfrastructureInterface
|
409
|
+
InfrastructureService
|
410
|
+
Network
|
411
|
+
Node
|
412
|
+
SystemSoftware
|
413
|
+
],
|
414
|
+
DEFAULT_RELATIONS)
|
415
|
+
|
416
|
+
define :Landscape_map, ViewpointTypeVal.new("Landscape Map",
|
417
|
+
ENTITIES + DataModel::ConnectorType.values,
|
418
|
+
DataModel::RelationshipType.values)
|
419
|
+
|
420
|
+
def self.[](idx)
|
421
|
+
values[idx]
|
422
|
+
end
|
423
|
+
end
|
424
|
+
|
425
|
+
VIEWPOINT_CONTENT_ENUM = %w[Details Coherence Overview].freeze
|
426
|
+
|
427
|
+
VIEWPOINT_PURPOSE_ENUM = %w[Designing Deciding Informing].freeze
|
428
|
+
end
|
429
|
+
end
|
@@ -19,10 +19,10 @@ module Archimate
|
|
19
19
|
"wb",
|
20
20
|
force_quotes: true
|
21
21
|
) do |csv|
|
22
|
-
headers = elements.first.
|
22
|
+
headers = elements.first.class.attr_names
|
23
23
|
csv << headers.map(&:to_s)
|
24
24
|
elements.each do |element|
|
25
|
-
csv << headers.map { |attr| element
|
25
|
+
csv << headers.map { |attr| element.send(attr) }
|
26
26
|
end
|
27
27
|
end
|
28
28
|
end
|
@@ -84,7 +84,7 @@ module Archimate
|
|
84
84
|
props = add_docs(
|
85
85
|
{
|
86
86
|
layer: element.layer.delete(" "),
|
87
|
-
name: element.name,
|
87
|
+
name: element.name.to_s,
|
88
88
|
nodeId: element.id
|
89
89
|
}.merge(
|
90
90
|
element.properties.each_with_object({}) do |prop, memo|
|
@@ -150,7 +150,7 @@ module Archimate
|
|
150
150
|
def relationship_def(rel)
|
151
151
|
h = add_docs(
|
152
152
|
{
|
153
|
-
name: rel.name,
|
153
|
+
name: rel.name.to_s,
|
154
154
|
relationshipId: rel.id,
|
155
155
|
accessType: rel.access_type,
|
156
156
|
weight: weight(rel.type)
|