rgen 0.9.1 → 0.10.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG +4 -0
- data/Project.yaml +2 -2
- data/lib/rgen/template_language/template_container.rb +1 -1
- data/test/metamodel_builder_test.rb +4 -5
- data/test/template_language_test.rb +1 -1
- metadata +169 -177
- data/test/metamodel_roundtrip_test/TestModel_Regenerated.rb +0 -71
- data/test/metamodel_roundtrip_test/houseMetamodel_Regenerated.ecore +0 -162
- data/test/metamodel_roundtrip_test/using_builtin_types_serialized.ecore +0 -9
- data/test/model_builder/ecore_internal.rb +0 -113
- data/test/template_language_test/line_endings_mixed.txt +0 -2
- data/test/template_language_test/line_endings_unix.txt +0 -2
- data/test/template_language_test/line_endings_windows.txt +0 -2
- data/test/testmodel/ea_testmodel_regenerated.xml +0 -813
- data/test/util/file_cache_map_test/testdir/fileA +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 718b7e6aeacd446bb08225196146552c65033210
|
4
|
+
data.tar.gz: cc635adbb4efece25018192e3252329908c33816
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: df6c209888d596ff60c3ec98727a725ff5bc3633c4623064394d3836348538d69e0ffa3fb279f9d41aade24fcc7620c3e5f5b0a32d38654f0509fc952991cbeb
|
7
|
+
data.tar.gz: 622b0cd9abe40acba98091eb0fdcb7c2abcc73cde5c755ed51da2792f22d1c40b7546eb71e2a8905305a1718c79d330686954056e2e81c3b76569ad3e0d25b5e
|
data/CHANGELOG
CHANGED
data/Project.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
name: rgen
|
2
2
|
gemspec: rgen.gemspec
|
3
3
|
git: https://github.com/mthiede/rgen.git
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
summary: Ruby Modelling and Generator Framework
|
6
6
|
email: martin dot thiede at gmx de
|
7
7
|
homepage: http://ruby-gen.org
|
@@ -15,7 +15,7 @@ exclude_files: ['**/*.bak']
|
|
15
15
|
encrypt_sources: false
|
16
16
|
dependencies:
|
17
17
|
https://rubygems.org:
|
18
|
-
- {name: nokogiri, version: ['>= 1.
|
18
|
+
- {name: nokogiri, version: ['>= 1.14.2', '< 1.15'], development: true}
|
19
19
|
- {name: rake, version: '~> 12.0', development: true}
|
20
20
|
- {name: minitest, version: ['~> 5.0', '>= 5.10.1'], development: true}
|
21
21
|
- {name: minitest-fail-fast, version: '~> 0.1.0', development: true}
|
@@ -29,7 +29,7 @@ module RGen
|
|
29
29
|
@@metamodels = @metamodels
|
30
30
|
fileContent = f.read
|
31
31
|
_detectNewLinePattern(fileContent)
|
32
|
-
ERB.new(fileContent,
|
32
|
+
ERB.new(fileContent, eoutvar:'@output').result(binding)
|
33
33
|
rescue Exception => e
|
34
34
|
processAndRaise(e)
|
35
35
|
end
|
@@ -226,7 +226,7 @@ class MetamodelBuilderTest < MiniTest::Test
|
|
226
226
|
err = assert_raises StandardError do
|
227
227
|
sc.allowed = :someSymbol
|
228
228
|
end
|
229
|
-
assert_match /In (\w+::)+SimpleClass : Can not use a Symbol\(:someSymbol\) where a \[true,false\] is expected/, err.message
|
229
|
+
assert_match /In (\w+::)+SimpleClass : Can not use a Symbol\(someSymbol\)\(:someSymbol\) where a \[true,false\] is expected/, err.message
|
230
230
|
err = assert_raises StandardError do
|
231
231
|
sc.allowed = "a string"
|
232
232
|
end
|
@@ -244,7 +244,7 @@ class MetamodelBuilderTest < MiniTest::Test
|
|
244
244
|
err = assert_raises StandardError do
|
245
245
|
sc.kind = :false
|
246
246
|
end
|
247
|
-
assert_match /In (\w+::)+SimpleClass : Can not use a Symbol\(:false\) where a \[:simple,:extended\] is expected/, err.message
|
247
|
+
assert_match /In (\w+::)+SimpleClass : Can not use a Symbol\(false\)\(:false\) where a \[:simple,:extended\] is expected/, err.message
|
248
248
|
err = assert_raises StandardError do
|
249
249
|
sc.kind = "a string"
|
250
250
|
end
|
@@ -280,7 +280,6 @@ class MetamodelBuilderTest < MiniTest::Test
|
|
280
280
|
assert_equal 5, sc.longWithDefault
|
281
281
|
sc.longWithDefault = (2**(0.size * 8 -2) -1) + 1
|
282
282
|
assert_equal (2**(0.size * 8 -2) -1) + 1, sc.longWithDefault
|
283
|
-
assert sc.longWithDefault.is_a?(Bignum)
|
284
283
|
assert sc.longWithDefault.is_a?(Integer)
|
285
284
|
err = assert_raises StandardError do
|
286
285
|
sc.longWithDefault = "a string"
|
@@ -616,7 +615,7 @@ class MetamodelBuilderTest < MiniTest::Test
|
|
616
615
|
err = assert_raises StandardError do
|
617
616
|
bc.addAClasses :notaaclass
|
618
617
|
end
|
619
|
-
assert_match /In (\w+::)+BClassMM : Can not use a Symbol\(:notaaclass\) where a (\w+::)+AClassMM is expected/, err.message
|
618
|
+
assert_match /In (\w+::)+BClassMM : Can not use a Symbol\(notaaclass\)\(:notaaclass\) where a (\w+::)+AClassMM is expected/, err.message
|
620
619
|
|
621
620
|
# remove the AClass from the BClass
|
622
621
|
bc.removeAClasses ac
|
@@ -632,7 +631,7 @@ class MetamodelBuilderTest < MiniTest::Test
|
|
632
631
|
err = assert_raises StandardError do
|
633
632
|
ac.addBClasses :notabclass
|
634
633
|
end
|
635
|
-
assert_match /In (\w+::)+AClassMM : Can not use a Symbol\(:notabclass\) where a (\w+::)+BClassMM is expected/, err.message
|
634
|
+
assert_match /In (\w+::)+AClassMM : Can not use a Symbol\(notabclass\)\(:notabclass\) where a (\w+::)+BClassMM is expected/, err.message
|
636
635
|
|
637
636
|
# remove the BClass from the AClass
|
638
637
|
ac.removeBClasses bc
|
@@ -61,7 +61,7 @@ class TemplateContainerTest < MiniTest::Test
|
|
61
61
|
def test_with_model
|
62
62
|
tc = RGen::TemplateLanguage::DirectoryTemplateContainer.new([MyMM, CCodeMM], OUTPUT_DIR)
|
63
63
|
tc.load(TEMPLATES_DIR)
|
64
|
-
File.delete(OUTPUT_DIR+"/testout.txt") if File.
|
64
|
+
File.delete(OUTPUT_DIR+"/testout.txt") if File.exist? OUTPUT_DIR+"/testout.txt"
|
65
65
|
tc.expand('root::Root', :for => TEST_MODEL, :indent => 1)
|
66
66
|
result = expected = ""
|
67
67
|
File.open(OUTPUT_DIR+"/testout.txt") {|f| result = f.read}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rgen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Martin Thiede
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-02-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -16,20 +16,20 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 1.
|
19
|
+
version: 1.14.2
|
20
20
|
- - "<"
|
21
21
|
- !ruby/object:Gem::Version
|
22
|
-
version: '1.
|
22
|
+
version: '1.15'
|
23
23
|
type: :development
|
24
24
|
prerelease: false
|
25
25
|
version_requirements: !ruby/object:Gem::Requirement
|
26
26
|
requirements:
|
27
27
|
- - ">="
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 1.
|
29
|
+
version: 1.14.2
|
30
30
|
- - "<"
|
31
31
|
- !ruby/object:Gem::Version
|
32
|
-
version: '1.
|
32
|
+
version: '1.15'
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
34
|
name: rake
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
@@ -95,7 +95,7 @@ dependencies:
|
|
95
95
|
description: RGen is a framework for Model Driven Software Development (MDSD) in Ruby.
|
96
96
|
This means that it helps you build Metamodels, instantiate Models, modify and transform
|
97
97
|
Models and finally generate arbitrary textual content from it.
|
98
|
-
email:
|
98
|
+
email:
|
99
99
|
executables: []
|
100
100
|
extensions: []
|
101
101
|
extra_rdoc_files:
|
@@ -103,181 +103,172 @@ extra_rdoc_files:
|
|
103
103
|
- CHANGELOG
|
104
104
|
- MIT-LICENSE
|
105
105
|
files:
|
106
|
-
- "./lib/ea_support/ea_support.rb"
|
107
|
-
- "./lib/ea_support/id_store.rb"
|
108
|
-
- "./lib/ea_support/uml13_ea_metamodel.rb"
|
109
|
-
- "./lib/ea_support/uml13_ea_metamodel_ext.rb"
|
110
|
-
- "./lib/ea_support/uml13_ea_metamodel_generator.rb"
|
111
|
-
- "./lib/ea_support/uml13_ea_to_uml13.rb"
|
112
|
-
- "./lib/ea_support/uml13_to_uml13_ea.rb"
|
113
|
-
- "./lib/metamodels/uml13_metamodel.rb"
|
114
|
-
- "./lib/metamodels/uml13_metamodel_ext.rb"
|
115
|
-
- "./lib/mmgen/metamodel_generator.rb"
|
116
|
-
- "./lib/mmgen/mm_ext/ecore_mmgen_ext.rb"
|
117
|
-
- "./lib/mmgen/mmgen.rb"
|
118
|
-
- "./lib/mmgen/templates/annotations.tpl"
|
119
|
-
- "./lib/mmgen/templates/metamodel_generator.tpl"
|
120
|
-
- "./lib/rgen/array_extensions.rb"
|
121
|
-
- "./lib/rgen/ecore/ecore.rb"
|
122
|
-
- "./lib/rgen/ecore/ecore_builder_methods.rb"
|
123
|
-
- "./lib/rgen/ecore/ecore_ext.rb"
|
124
|
-
- "./lib/rgen/ecore/ecore_interface.rb"
|
125
|
-
- "./lib/rgen/ecore/ecore_to_json.rb"
|
126
|
-
- "./lib/rgen/ecore/ecore_to_ruby.rb"
|
127
|
-
- "./lib/rgen/ecore/ruby_to_ecore.rb"
|
128
|
-
- "./lib/rgen/environment.rb"
|
129
|
-
- "./lib/rgen/fragment/dump_file_cache.rb"
|
130
|
-
- "./lib/rgen/fragment/fragmented_model.rb"
|
131
|
-
- "./lib/rgen/fragment/model_fragment.rb"
|
132
|
-
- "./lib/rgen/instantiator/abstract_instantiator.rb"
|
133
|
-
- "./lib/rgen/instantiator/abstract_xml_instantiator.rb"
|
134
|
-
- "./lib/rgen/instantiator/default_xml_instantiator.rb"
|
135
|
-
- "./lib/rgen/instantiator/ecore_xml_instantiator.rb"
|
136
|
-
- "./lib/rgen/instantiator/json_instantiator.rb"
|
137
|
-
- "./lib/rgen/instantiator/json_parser.rb"
|
138
|
-
- "./lib/rgen/instantiator/json_parser.y"
|
139
|
-
- "./lib/rgen/instantiator/nodebased_xml_instantiator.rb"
|
140
|
-
- "./lib/rgen/instantiator/qualified_name_resolver.rb"
|
141
|
-
- "./lib/rgen/instantiator/reference_resolver.rb"
|
142
|
-
- "./lib/rgen/instantiator/resolution_helper.rb"
|
143
|
-
- "./lib/rgen/instantiator/xmi11_instantiator.rb"
|
144
|
-
- "./lib/rgen/metamodel_builder.rb"
|
145
|
-
- "./lib/rgen/metamodel_builder/builder_extensions.rb"
|
146
|
-
- "./lib/rgen/metamodel_builder/builder_runtime.rb"
|
147
|
-
- "./lib/rgen/metamodel_builder/constant_order_helper.rb"
|
148
|
-
- "./lib/rgen/metamodel_builder/data_types.rb"
|
149
|
-
- "./lib/rgen/metamodel_builder/intermediate/annotation.rb"
|
150
|
-
- "./lib/rgen/metamodel_builder/intermediate/feature.rb"
|
151
|
-
- "./lib/rgen/metamodel_builder/mm_multiple.rb"
|
152
|
-
- "./lib/rgen/metamodel_builder/module_extension.rb"
|
153
|
-
- "./lib/rgen/model_builder.rb"
|
154
|
-
- "./lib/rgen/model_builder/builder_context.rb"
|
155
|
-
- "./lib/rgen/model_builder/model_serializer.rb"
|
156
|
-
- "./lib/rgen/model_builder/reference_resolver.rb"
|
157
|
-
- "./lib/rgen/serializer/json_serializer.rb"
|
158
|
-
- "./lib/rgen/serializer/opposite_reference_filter.rb"
|
159
|
-
- "./lib/rgen/serializer/qualified_name_provider.rb"
|
160
|
-
- "./lib/rgen/serializer/xmi11_serializer.rb"
|
161
|
-
- "./lib/rgen/serializer/xmi20_serializer.rb"
|
162
|
-
- "./lib/rgen/serializer/xml_serializer.rb"
|
163
|
-
- "./lib/rgen/template_language.rb"
|
164
|
-
- "./lib/rgen/template_language/directory_template_container.rb"
|
165
|
-
- "./lib/rgen/template_language/output_handler.rb"
|
166
|
-
- "./lib/rgen/template_language/template_container.rb"
|
167
|
-
- "./lib/rgen/template_language/template_helper.rb"
|
168
|
-
- "./lib/rgen/transformer.rb"
|
169
|
-
- "./lib/rgen/util/auto_class_creator.rb"
|
170
|
-
- "./lib/rgen/util/cached_glob.rb"
|
171
|
-
- "./lib/rgen/util/file_cache_map.rb"
|
172
|
-
- "./lib/rgen/util/file_change_detector.rb"
|
173
|
-
- "./lib/rgen/util/method_delegation.rb"
|
174
|
-
- "./lib/rgen/util/model_comparator.rb"
|
175
|
-
- "./lib/rgen/util/model_comparator_base.rb"
|
176
|
-
- "./lib/rgen/util/model_dumper.rb"
|
177
|
-
- "./lib/rgen/util/name_helper.rb"
|
178
|
-
- "./lib/rgen/util/pattern_matcher.rb"
|
179
|
-
- "./lib/transformers/ecore_to_uml13.rb"
|
180
|
-
- "./lib/transformers/uml13_to_ecore.rb"
|
181
|
-
- "./test/array_extensions_test.rb"
|
182
|
-
- "./test/ea_instantiator_test.rb"
|
183
|
-
- "./test/ea_serializer_test.rb"
|
184
|
-
- "./test/ecore_self_test.rb"
|
185
|
-
- "./test/ecore_to_ruby_test.rb"
|
186
|
-
- "./test/environment_test.rb"
|
187
|
-
- "./test/json_test.rb"
|
188
|
-
- "./test/metamodel_builder_test.rb"
|
189
|
-
- "./test/metamodel_from_ecore_test.rb"
|
190
|
-
- "./test/metamodel_order_test.rb"
|
191
|
-
- "./test/metamodel_roundtrip_test.rb"
|
192
|
-
- "./test/metamodel_roundtrip_test/TestModel.rb"
|
193
|
-
- "./test/metamodel_roundtrip_test/TestModel_Regenerated.rb"
|
194
|
-
- "./test/metamodel_roundtrip_test/houseMetamodel.ecore"
|
195
|
-
- "./test/metamodel_roundtrip_test/houseMetamodel_Regenerated.ecore"
|
196
|
-
- "./test/metamodel_roundtrip_test/houseMetamodel_from_ecore.rb"
|
197
|
-
- "./test/metamodel_roundtrip_test/using_builtin_types.ecore"
|
198
|
-
- "./test/metamodel_roundtrip_test/using_builtin_types_serialized.ecore"
|
199
|
-
- "./test/method_delegation_test.rb"
|
200
|
-
- "./test/model_builder/builder_context_test.rb"
|
201
|
-
- "./test/model_builder/builder_test.rb"
|
202
|
-
- "./test/model_builder/ecore_internal.rb"
|
203
|
-
- "./test/model_builder/ecore_original.rb"
|
204
|
-
- "./test/model_builder/ecore_original_regenerated.rb"
|
205
|
-
- "./test/model_builder/reference_resolver_test.rb"
|
206
|
-
- "./test/model_builder/serializer_test.rb"
|
207
|
-
- "./test/model_builder/statemachine_metamodel.rb"
|
208
|
-
- "./test/model_builder/test_model/statemachine1.rb"
|
209
|
-
- "./test/model_builder_test.rb"
|
210
|
-
- "./test/model_fragment_test.rb"
|
211
|
-
- "./test/output_handler_test.rb"
|
212
|
-
- "./test/qualified_name_provider_test.rb"
|
213
|
-
- "./test/qualified_name_resolver_test.rb"
|
214
|
-
- "./test/reference_resolver_test.rb"
|
215
|
-
- "./test/rgen_test.rb"
|
216
|
-
- "./test/template_language_test.rb"
|
217
|
-
- "./test/template_language_test/expected_result1.txt"
|
218
|
-
- "./test/template_language_test/expected_result2.txt"
|
219
|
-
- "./test/template_language_test/expected_result3.txt"
|
220
|
-
- "./test/template_language_test/indentStringTestDefaultIndent.out"
|
221
|
-
- "./test/template_language_test/indentStringTestTabIndent.out"
|
222
|
-
- "./test/template_language_test/line_endings_mixed.txt"
|
223
|
-
- "./test/template_language_test/line_endings_unix.txt"
|
224
|
-
- "./test/template_language_test/line_endings_windows.txt"
|
225
|
-
- "./test/template_language_test/templates/callback_indent_test/a.tpl"
|
226
|
-
- "./test/template_language_test/templates/callback_indent_test/b.tpl"
|
227
|
-
- "./test/template_language_test/templates/code/array.tpl"
|
228
|
-
- "./test/template_language_test/templates/content/author.tpl"
|
229
|
-
- "./test/template_language_test/templates/content/chapter.tpl"
|
230
|
-
- "./test/template_language_test/templates/define_local_test/local.tpl"
|
231
|
-
- "./test/template_language_test/templates/define_local_test/test.tpl"
|
232
|
-
- "./test/template_language_test/templates/evaluate_test/test.tpl"
|
233
|
-
- "./test/template_language_test/templates/indent_nonl_at_eof_test/test.tpl"
|
234
|
-
- "./test/template_language_test/templates/indent_same_line_sub/test.tpl"
|
235
|
-
- "./test/template_language_test/templates/indent_string_test.tpl"
|
236
|
-
- "./test/template_language_test/templates/index/c/cmod.tpl"
|
237
|
-
- "./test/template_language_test/templates/index/chapter.tpl"
|
238
|
-
- "./test/template_language_test/templates/line_endings/mixed.tpl"
|
239
|
-
- "./test/template_language_test/templates/line_endings/unix.tpl"
|
240
|
-
- "./test/template_language_test/templates/line_endings/windows.tpl"
|
241
|
-
- "./test/template_language_test/templates/no_backslash_r_test.tpl"
|
242
|
-
- "./test/template_language_test/templates/no_indent_test/no_indent.tpl"
|
243
|
-
- "./test/template_language_test/templates/no_indent_test/sub1/no_indent.tpl"
|
244
|
-
- "./test/template_language_test/templates/no_indent_test/test.tpl"
|
245
|
-
- "./test/template_language_test/templates/no_indent_test/test2.tpl"
|
246
|
-
- "./test/template_language_test/templates/no_indent_test/test3.tpl"
|
247
|
-
- "./test/template_language_test/templates/null_context_test.tpl"
|
248
|
-
- "./test/template_language_test/templates/root.tpl"
|
249
|
-
- "./test/template_language_test/templates/template_resolution_test/sub1.tpl"
|
250
|
-
- "./test/template_language_test/templates/template_resolution_test/sub1/sub1.tpl"
|
251
|
-
- "./test/template_language_test/templates/template_resolution_test/test.tpl"
|
252
|
-
- "./test/template_language_test/templates/ws_test.tpl"
|
253
|
-
- "./test/template_language_test/testout.txt"
|
254
|
-
- "./test/testmodel/class_model_checker.rb"
|
255
|
-
- "./test/testmodel/ea_testmodel.eap"
|
256
|
-
- "./test/testmodel/ea_testmodel.xml"
|
257
|
-
- "./test/testmodel/ea_testmodel_partial.xml"
|
258
|
-
- "./test/testmodel/ea_testmodel_regenerated.xml"
|
259
|
-
- "./test/testmodel/ecore_model_checker.rb"
|
260
|
-
- "./test/testmodel/manual_testmodel.xml"
|
261
|
-
- "./test/testmodel/object_model_checker.rb"
|
262
|
-
- "./test/transformer_test.rb"
|
263
|
-
- "./test/util/file_cache_map_test.rb"
|
264
|
-
- "./test/util/file_cache_map_test/testdir/fileA"
|
265
|
-
- "./test/util/pattern_matcher_test.rb"
|
266
|
-
- "./test/util_test.rb"
|
267
|
-
- "./test/xml_instantiator_test.rb"
|
268
|
-
- "./test/xml_instantiator_test/simple_ecore_model_checker.rb"
|
269
|
-
- "./test/xml_instantiator_test/simple_xmi_ecore_instantiator.rb"
|
270
|
-
- "./test/xml_instantiator_test/simple_xmi_metamodel.rb"
|
271
|
-
- "./test/xml_instantiator_test/simple_xmi_to_ecore.rb"
|
272
106
|
- CHANGELOG
|
273
107
|
- MIT-LICENSE
|
274
108
|
- Project.yaml
|
275
109
|
- README.rdoc
|
276
110
|
- Rakefile
|
111
|
+
- lib/ea_support/ea_support.rb
|
112
|
+
- lib/ea_support/id_store.rb
|
113
|
+
- lib/ea_support/uml13_ea_metamodel.rb
|
114
|
+
- lib/ea_support/uml13_ea_metamodel_ext.rb
|
115
|
+
- lib/ea_support/uml13_ea_metamodel_generator.rb
|
116
|
+
- lib/ea_support/uml13_ea_to_uml13.rb
|
117
|
+
- lib/ea_support/uml13_to_uml13_ea.rb
|
118
|
+
- lib/metamodels/uml13_metamodel.rb
|
119
|
+
- lib/metamodels/uml13_metamodel_ext.rb
|
120
|
+
- lib/mmgen/metamodel_generator.rb
|
121
|
+
- lib/mmgen/mm_ext/ecore_mmgen_ext.rb
|
122
|
+
- lib/mmgen/mmgen.rb
|
123
|
+
- lib/mmgen/templates/annotations.tpl
|
124
|
+
- lib/mmgen/templates/metamodel_generator.tpl
|
125
|
+
- lib/rgen/array_extensions.rb
|
126
|
+
- lib/rgen/ecore/ecore.rb
|
127
|
+
- lib/rgen/ecore/ecore_builder_methods.rb
|
128
|
+
- lib/rgen/ecore/ecore_ext.rb
|
129
|
+
- lib/rgen/ecore/ecore_interface.rb
|
130
|
+
- lib/rgen/ecore/ecore_to_json.rb
|
131
|
+
- lib/rgen/ecore/ecore_to_ruby.rb
|
132
|
+
- lib/rgen/ecore/ruby_to_ecore.rb
|
133
|
+
- lib/rgen/environment.rb
|
134
|
+
- lib/rgen/fragment/dump_file_cache.rb
|
135
|
+
- lib/rgen/fragment/fragmented_model.rb
|
136
|
+
- lib/rgen/fragment/model_fragment.rb
|
137
|
+
- lib/rgen/instantiator/abstract_instantiator.rb
|
138
|
+
- lib/rgen/instantiator/abstract_xml_instantiator.rb
|
139
|
+
- lib/rgen/instantiator/default_xml_instantiator.rb
|
140
|
+
- lib/rgen/instantiator/ecore_xml_instantiator.rb
|
141
|
+
- lib/rgen/instantiator/json_instantiator.rb
|
142
|
+
- lib/rgen/instantiator/json_parser.rb
|
143
|
+
- lib/rgen/instantiator/json_parser.y
|
144
|
+
- lib/rgen/instantiator/nodebased_xml_instantiator.rb
|
145
|
+
- lib/rgen/instantiator/qualified_name_resolver.rb
|
146
|
+
- lib/rgen/instantiator/reference_resolver.rb
|
147
|
+
- lib/rgen/instantiator/resolution_helper.rb
|
148
|
+
- lib/rgen/instantiator/xmi11_instantiator.rb
|
149
|
+
- lib/rgen/metamodel_builder.rb
|
150
|
+
- lib/rgen/metamodel_builder/builder_extensions.rb
|
151
|
+
- lib/rgen/metamodel_builder/builder_runtime.rb
|
152
|
+
- lib/rgen/metamodel_builder/constant_order_helper.rb
|
153
|
+
- lib/rgen/metamodel_builder/data_types.rb
|
154
|
+
- lib/rgen/metamodel_builder/intermediate/annotation.rb
|
155
|
+
- lib/rgen/metamodel_builder/intermediate/feature.rb
|
156
|
+
- lib/rgen/metamodel_builder/mm_multiple.rb
|
157
|
+
- lib/rgen/metamodel_builder/module_extension.rb
|
158
|
+
- lib/rgen/model_builder.rb
|
159
|
+
- lib/rgen/model_builder/builder_context.rb
|
160
|
+
- lib/rgen/model_builder/model_serializer.rb
|
161
|
+
- lib/rgen/model_builder/reference_resolver.rb
|
162
|
+
- lib/rgen/serializer/json_serializer.rb
|
163
|
+
- lib/rgen/serializer/opposite_reference_filter.rb
|
164
|
+
- lib/rgen/serializer/qualified_name_provider.rb
|
165
|
+
- lib/rgen/serializer/xmi11_serializer.rb
|
166
|
+
- lib/rgen/serializer/xmi20_serializer.rb
|
167
|
+
- lib/rgen/serializer/xml_serializer.rb
|
168
|
+
- lib/rgen/template_language.rb
|
169
|
+
- lib/rgen/template_language/directory_template_container.rb
|
170
|
+
- lib/rgen/template_language/output_handler.rb
|
171
|
+
- lib/rgen/template_language/template_container.rb
|
172
|
+
- lib/rgen/template_language/template_helper.rb
|
173
|
+
- lib/rgen/transformer.rb
|
174
|
+
- lib/rgen/util/auto_class_creator.rb
|
175
|
+
- lib/rgen/util/cached_glob.rb
|
176
|
+
- lib/rgen/util/file_cache_map.rb
|
177
|
+
- lib/rgen/util/file_change_detector.rb
|
178
|
+
- lib/rgen/util/method_delegation.rb
|
179
|
+
- lib/rgen/util/model_comparator.rb
|
180
|
+
- lib/rgen/util/model_comparator_base.rb
|
181
|
+
- lib/rgen/util/model_dumper.rb
|
182
|
+
- lib/rgen/util/name_helper.rb
|
183
|
+
- lib/rgen/util/pattern_matcher.rb
|
184
|
+
- lib/transformers/ecore_to_uml13.rb
|
185
|
+
- lib/transformers/uml13_to_ecore.rb
|
186
|
+
- test/array_extensions_test.rb
|
187
|
+
- test/ea_instantiator_test.rb
|
188
|
+
- test/ea_serializer_test.rb
|
189
|
+
- test/ecore_self_test.rb
|
190
|
+
- test/ecore_to_ruby_test.rb
|
191
|
+
- test/environment_test.rb
|
192
|
+
- test/json_test.rb
|
193
|
+
- test/metamodel_builder_test.rb
|
194
|
+
- test/metamodel_from_ecore_test.rb
|
195
|
+
- test/metamodel_order_test.rb
|
196
|
+
- test/metamodel_roundtrip_test.rb
|
197
|
+
- test/metamodel_roundtrip_test/TestModel.rb
|
198
|
+
- test/metamodel_roundtrip_test/houseMetamodel.ecore
|
199
|
+
- test/metamodel_roundtrip_test/houseMetamodel_from_ecore.rb
|
200
|
+
- test/metamodel_roundtrip_test/using_builtin_types.ecore
|
201
|
+
- test/method_delegation_test.rb
|
202
|
+
- test/model_builder/builder_context_test.rb
|
203
|
+
- test/model_builder/builder_test.rb
|
204
|
+
- test/model_builder/ecore_original.rb
|
205
|
+
- test/model_builder/ecore_original_regenerated.rb
|
206
|
+
- test/model_builder/reference_resolver_test.rb
|
207
|
+
- test/model_builder/serializer_test.rb
|
208
|
+
- test/model_builder/statemachine_metamodel.rb
|
209
|
+
- test/model_builder/test_model/statemachine1.rb
|
210
|
+
- test/model_builder_test.rb
|
211
|
+
- test/model_fragment_test.rb
|
212
|
+
- test/output_handler_test.rb
|
213
|
+
- test/qualified_name_provider_test.rb
|
214
|
+
- test/qualified_name_resolver_test.rb
|
215
|
+
- test/reference_resolver_test.rb
|
216
|
+
- test/rgen_test.rb
|
217
|
+
- test/template_language_test.rb
|
218
|
+
- test/template_language_test/expected_result1.txt
|
219
|
+
- test/template_language_test/expected_result2.txt
|
220
|
+
- test/template_language_test/expected_result3.txt
|
221
|
+
- test/template_language_test/indentStringTestDefaultIndent.out
|
222
|
+
- test/template_language_test/indentStringTestTabIndent.out
|
223
|
+
- test/template_language_test/templates/callback_indent_test/a.tpl
|
224
|
+
- test/template_language_test/templates/callback_indent_test/b.tpl
|
225
|
+
- test/template_language_test/templates/code/array.tpl
|
226
|
+
- test/template_language_test/templates/content/author.tpl
|
227
|
+
- test/template_language_test/templates/content/chapter.tpl
|
228
|
+
- test/template_language_test/templates/define_local_test/local.tpl
|
229
|
+
- test/template_language_test/templates/define_local_test/test.tpl
|
230
|
+
- test/template_language_test/templates/evaluate_test/test.tpl
|
231
|
+
- test/template_language_test/templates/indent_nonl_at_eof_test/test.tpl
|
232
|
+
- test/template_language_test/templates/indent_same_line_sub/test.tpl
|
233
|
+
- test/template_language_test/templates/indent_string_test.tpl
|
234
|
+
- test/template_language_test/templates/index/c/cmod.tpl
|
235
|
+
- test/template_language_test/templates/index/chapter.tpl
|
236
|
+
- test/template_language_test/templates/line_endings/mixed.tpl
|
237
|
+
- test/template_language_test/templates/line_endings/unix.tpl
|
238
|
+
- test/template_language_test/templates/line_endings/windows.tpl
|
239
|
+
- test/template_language_test/templates/no_backslash_r_test.tpl
|
240
|
+
- test/template_language_test/templates/no_indent_test/no_indent.tpl
|
241
|
+
- test/template_language_test/templates/no_indent_test/sub1/no_indent.tpl
|
242
|
+
- test/template_language_test/templates/no_indent_test/test.tpl
|
243
|
+
- test/template_language_test/templates/no_indent_test/test2.tpl
|
244
|
+
- test/template_language_test/templates/no_indent_test/test3.tpl
|
245
|
+
- test/template_language_test/templates/null_context_test.tpl
|
246
|
+
- test/template_language_test/templates/root.tpl
|
247
|
+
- test/template_language_test/templates/template_resolution_test/sub1.tpl
|
248
|
+
- test/template_language_test/templates/template_resolution_test/sub1/sub1.tpl
|
249
|
+
- test/template_language_test/templates/template_resolution_test/test.tpl
|
250
|
+
- test/template_language_test/templates/ws_test.tpl
|
251
|
+
- test/template_language_test/testout.txt
|
252
|
+
- test/testmodel/class_model_checker.rb
|
253
|
+
- test/testmodel/ea_testmodel.eap
|
254
|
+
- test/testmodel/ea_testmodel.xml
|
255
|
+
- test/testmodel/ea_testmodel_partial.xml
|
256
|
+
- test/testmodel/ecore_model_checker.rb
|
257
|
+
- test/testmodel/manual_testmodel.xml
|
258
|
+
- test/testmodel/object_model_checker.rb
|
259
|
+
- test/transformer_test.rb
|
260
|
+
- test/util/file_cache_map_test.rb
|
261
|
+
- test/util/pattern_matcher_test.rb
|
262
|
+
- test/util_test.rb
|
263
|
+
- test/xml_instantiator_test.rb
|
264
|
+
- test/xml_instantiator_test/simple_ecore_model_checker.rb
|
265
|
+
- test/xml_instantiator_test/simple_xmi_ecore_instantiator.rb
|
266
|
+
- test/xml_instantiator_test/simple_xmi_metamodel.rb
|
267
|
+
- test/xml_instantiator_test/simple_xmi_to_ecore.rb
|
277
268
|
homepage: http://ruby-gen.org
|
278
269
|
licenses: []
|
279
270
|
metadata: {}
|
280
|
-
post_install_message:
|
271
|
+
post_install_message:
|
281
272
|
rdoc_options:
|
282
273
|
- "--main"
|
283
274
|
- README.rdoc
|
@@ -300,8 +291,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
300
291
|
- !ruby/object:Gem::Version
|
301
292
|
version: '0'
|
302
293
|
requirements: []
|
303
|
-
|
304
|
-
|
294
|
+
rubyforge_project:
|
295
|
+
rubygems_version: 2.6.14
|
296
|
+
signing_key:
|
305
297
|
specification_version: 4
|
306
298
|
summary: Ruby Modelling and Generator Framework
|
307
299
|
test_files: []
|
@@ -1,71 +0,0 @@
|
|
1
|
-
require 'rgen/metamodel_builder'
|
2
|
-
|
3
|
-
module HouseMetamodel
|
4
|
-
extend RGen::MetamodelBuilder::ModuleExtension
|
5
|
-
include RGen::MetamodelBuilder::DataTypes
|
6
|
-
|
7
|
-
SexEnum = Enum.new(:name => 'SexEnum', :literals =>[ :male, :female ])
|
8
|
-
|
9
|
-
class MeetingPlace < RGen::MetamodelBuilder::MMBase
|
10
|
-
annotation :source => "testmodel", :details => {'complexity' => '1', 'date_created' => '2006-07-12 08:40:46', 'date_modified' => '2006-07-12 08:44:02', 'ea_ntype' => '0', 'ea_stype' => 'Class', 'gentype' => 'Java', 'isSpecification' => 'false', 'package' => 'EAPK_A1B83D59_CAE1_422c_BA5F_D3624D7156AD', 'package_name' => 'HouseMetamodel', 'phase' => '1.0', 'status' => 'Proposed', 'style' => 'BackColor=-1;BorderColor=-1;BorderWidth=-1;FontColor=-1;VSwimLanes=0;HSwimLanes=0;BorderStyle=0;', 'tagged' => '0', 'version' => '1.0'}
|
11
|
-
end
|
12
|
-
|
13
|
-
class Person < RGen::MetamodelBuilder::MMBase
|
14
|
-
annotation 'complexity' => '1', 'date_created' => '2006-06-27 08:34:23', 'date_modified' => '2006-06-27 08:34:26', 'ea_ntype' => '0', 'ea_stype' => 'Class', 'gentype' => 'Java', 'isSpecification' => 'false', 'package' => 'EAPK_A1B83D59_CAE1_422c_BA5F_D3624D7156AD', 'package_name' => 'HouseMetamodel', 'phase' => '1.0', 'status' => 'Proposed', 'style' => 'BackColor=-1;BorderColor=-1;BorderWidth=-1;FontColor=-1;VSwimLanes=0;HSwimLanes=0;BorderStyle=0;', 'tagged' => '0', 'version' => '1.0'
|
15
|
-
has_attr 'sex', HouseMetamodel::SexEnum
|
16
|
-
has_attr 'id', Long
|
17
|
-
has_many_attr 'nicknames', String
|
18
|
-
end
|
19
|
-
|
20
|
-
class House < RGen::MetamodelBuilder::MMBase
|
21
|
-
annotation 'complexity' => '1', 'date_created' => '2005-09-16 19:52:18', 'date_modified' => '2006-02-28 08:29:19', 'ea_ntype' => '0', 'ea_stype' => 'Class', 'gentype' => 'Java', 'isSpecification' => 'false', 'package' => 'EAPK_A1B83D59_CAE1_422c_BA5F_D3624D7156AD', 'package_name' => 'HouseMetamodel', 'phase' => '1.0', 'status' => 'Proposed', 'stereotype' => 'dummy', 'style' => 'BackColor=-1;BorderColor=-1;BorderWidth=-1;FontColor=-1;VSwimLanes=0;HSwimLanes=0;BorderStyle=0;', 'tagged' => '0', 'version' => '1.0'
|
22
|
-
has_attr 'size', Integer
|
23
|
-
has_attr 'module', String
|
24
|
-
has_attr 'address', String, :changeable => false do
|
25
|
-
annotation 'collection' => 'false', 'containment' => 'Not Specified', 'derived' => '0', 'duplicates' => '0', 'ea_guid' => '{A8DF581B-9AC6-4f75-AB48-8FAEDFC6E068}', 'lowerBound' => '1', 'ordered' => '0', 'position' => '0', 'styleex' => 'volatile=0;', 'type' => 'String', 'upperBound' => '1'
|
26
|
-
end
|
27
|
-
end
|
28
|
-
|
29
|
-
|
30
|
-
module Rooms
|
31
|
-
extend RGen::MetamodelBuilder::ModuleExtension
|
32
|
-
include RGen::MetamodelBuilder::DataTypes
|
33
|
-
|
34
|
-
|
35
|
-
class Room < RGen::MetamodelBuilder::MMBase
|
36
|
-
abstract
|
37
|
-
annotation 'complexity' => '1', 'date_created' => '2005-09-16 19:52:28', 'date_modified' => '2006-06-22 21:15:25', 'ea_ntype' => '0', 'ea_stype' => 'Class', 'gentype' => 'Java', 'isSpecification' => 'false', 'package' => 'EAPK_F9D8C6E3_4DAD_4aa2_AD47_D0ABA4E93E08', 'package_name' => 'Rooms', 'phase' => '1.0', 'status' => 'Proposed', 'style' => 'BackColor=-1;BorderColor=-1;BorderWidth=-1;FontColor=-1;VSwimLanes=0;HSwimLanes=0;BorderStyle=0;', 'tagged' => '0', 'version' => '1.0'
|
38
|
-
end
|
39
|
-
|
40
|
-
class Bathroom < Room
|
41
|
-
annotation 'complexity' => '1', 'date_created' => '2006-06-27 08:32:25', 'date_modified' => '2006-06-27 08:34:23', 'ea_ntype' => '0', 'ea_stype' => 'Class', 'gentype' => 'Java', 'isSpecification' => 'false', 'package' => 'EAPK_F9D8C6E3_4DAD_4aa2_AD47_D0ABA4E93E08', 'package_name' => 'Rooms', 'phase' => '1.0', 'status' => 'Proposed', 'style' => 'BackColor=-1;BorderColor=-1;BorderWidth=-1;FontColor=-1;VSwimLanes=0;HSwimLanes=0;BorderStyle=0;', 'tagged' => '0', 'version' => '1.0'
|
42
|
-
end
|
43
|
-
|
44
|
-
class Kitchen < RGen::MetamodelBuilder::MMMultiple(HouseMetamodel::MeetingPlace, Room)
|
45
|
-
annotation 'complexity' => '1', 'date_created' => '2005-11-30 19:26:13', 'date_modified' => '2006-06-22 21:15:34', 'ea_ntype' => '0', 'ea_stype' => 'Class', 'gentype' => 'Java', 'isSpecification' => 'false', 'package' => 'EAPK_F9D8C6E3_4DAD_4aa2_AD47_D0ABA4E93E08', 'package_name' => 'Rooms', 'phase' => '1.0', 'status' => 'Proposed', 'style' => 'BackColor=-1;BorderColor=-1;BorderWidth=-1;FontColor=-1;VSwimLanes=0;HSwimLanes=0;BorderStyle=0;', 'tagged' => '0', 'version' => '1.0'
|
46
|
-
end
|
47
|
-
|
48
|
-
end
|
49
|
-
|
50
|
-
module DependingOnRooms
|
51
|
-
extend RGen::MetamodelBuilder::ModuleExtension
|
52
|
-
include RGen::MetamodelBuilder::DataTypes
|
53
|
-
|
54
|
-
|
55
|
-
class RoomSub < HouseMetamodel::Rooms::Room
|
56
|
-
end
|
57
|
-
|
58
|
-
end
|
59
|
-
end
|
60
|
-
|
61
|
-
HouseMetamodel::Person.has_many 'home', HouseMetamodel::House do
|
62
|
-
annotation 'containment' => 'Unspecified'
|
63
|
-
end
|
64
|
-
HouseMetamodel::House.has_one 'bathroom', HouseMetamodel::Rooms::Bathroom, :lowerBound => 1, :transient => true
|
65
|
-
HouseMetamodel::House.one_to_one 'kitchen', HouseMetamodel::Rooms::Kitchen, 'house', :lowerBound => 1, :opposite_lowerBound => 1 do
|
66
|
-
annotation 'containment' => 'Unspecified'
|
67
|
-
opposite_annotation 'containment' => 'Unspecified'
|
68
|
-
end
|
69
|
-
HouseMetamodel::House.contains_many 'room', HouseMetamodel::Rooms::Room, 'house', :lowerBound => 1 do
|
70
|
-
opposite_annotation 'containment' => 'Unspecified'
|
71
|
-
end
|