|
@@ -275,7 +275,6 @@ Void function model_overwrite(model : Element, model_id : String):
|
|
|
|
|
|
location = "/models/" + cast_id2s(model)
|
|
|
export_node(location, model)
|
|
|
- log("Got model ID: " + model_id)
|
|
|
|
|
|
// Change location in meta-data
|
|
|
unset_attribute(core, model_id, "location")
|
|
@@ -639,7 +638,6 @@ Void function user_function_skip_init(user_id : String):
|
|
|
// Add tracability links at this level
|
|
|
while (read_nr_out(all_formalisms) > 0):
|
|
|
source_formalism_id = get_model_id(list_read(set_pop(all_formalisms), 0))
|
|
|
- log("ADD tracability link to " + source_formalism_id)
|
|
|
tracability_link = instantiate_link(core, "tracability", "", merged_formalism_id, source_formalism_id)
|
|
|
instantiate_attribute(core, tracability_link, "type", "merged")
|
|
|
|
|
@@ -683,20 +681,14 @@ Void function user_function_skip_init(user_id : String):
|
|
|
if (allow_read(user_id, ramified_metamodel_id)):
|
|
|
output("Supported metamodels:")
|
|
|
links = allOutgoingAssociationInstances(core, ramified_metamodel_id, "tracability")
|
|
|
- log(set_to_string(links))
|
|
|
while (read_nr_out(links) > 0):
|
|
|
link_id = set_pop(links)
|
|
|
- log("CHECK " + link_id)
|
|
|
merged_metamodel_id = readAssociationDestination(core, link_id)
|
|
|
- log("Merged: " + merged_metamodel_id)
|
|
|
if (value_eq(read_attribute(core, link_id, "type"), "RAMified")):
|
|
|
links_merged = allOutgoingAssociationInstances(core, merged_metamodel_id, "tracability")
|
|
|
- log(set_to_string(links_merged))
|
|
|
while (read_nr_out(links_merged) > 0):
|
|
|
merged_link_id = set_pop(links_merged)
|
|
|
- log("CHECK2 " + merged_link_id)
|
|
|
if (value_eq(read_attribute(core, merged_link_id, "type"), "merged")):
|
|
|
- log("Found match!")
|
|
|
output(string_join(" ", read_attribute(core, readAssociationDestination(core, merged_link_id), "name")))
|
|
|
set_add(supported, readAssociationDestination(core, merged_link_id))
|
|
|
|
|
@@ -750,13 +742,9 @@ Void function user_function_skip_init(user_id : String):
|
|
|
|
|
|
// Extend metadata with info on source and target
|
|
|
while (read_nr_out(source) > 0):
|
|
|
- log("Instantiate source link")
|
|
|
instantiate_link(core, "transformInput", "", model_id, set_pop(source))
|
|
|
- log("OK")
|
|
|
while (read_nr_out(target) > 0):
|
|
|
- log("Instantiate target link")
|
|
|
instantiate_link(core, "transformOutput", "", model_id, set_pop(target))
|
|
|
- log("OK")
|
|
|
|
|
|
output("Meta-info correctly set!")
|
|
|
else:
|
|
@@ -773,7 +761,6 @@ Void function user_function_skip_init(user_id : String):
|
|
|
String type
|
|
|
|
|
|
models = allInstances(core, "Transformation")
|
|
|
- log("Instances: " + set_to_string(models))
|
|
|
while (read_nr_out(models) > 0):
|
|
|
m = set_pop(models)
|
|
|
output(string_join(("[" + read_type(core, m)) + "]", string_join((string_join(" ", read_attribute(core, m, "name")) + " : "), read_attribute(core, set_pop(followAssociation(core, m, "instanceOf")), "name"))))
|