Browse Source

Also save merged metamodel for model transformations

Yentl Van Tendeloo 7 years ago
parent
commit
bc765041df
1 changed files with 2 additions and 4 deletions
  1. 2 4
      bootstrap/core_algorithm.alc

+ 2 - 4
bootstrap/core_algorithm.alc

@@ -1046,7 +1046,6 @@ String function cmd_transformation_between(source_dict : String, target_dict : S
 	String link
 	Element keys
 
-	log("Finding transformation from " + dict_to_string(source_dict) + " to " + dict_to_string(target_dict))
 	result = allInstances(core, "Transformation")
 
 	// Iterate over all inputs
@@ -1099,7 +1098,6 @@ String function cmd_transformation_between(source_dict : String, target_dict : S
 		transformation = set_pop(result)
 		if (allow_read(current_user_id, transformation)):
 			r = r + string_join(full_name(transformation), "\n")
-			log("Found: " + full_name(transformation))
 	return r!
 
 String function cmd_model_rendered(model_name : String, mapper_name : String):
@@ -1658,7 +1656,6 @@ String function transformation_add(source_models : Element, target_models : Elem
 			keys = dict_keys(source)
 			while (set_len(keys) > 0):
 				key = set_pop(keys)
-				log("Add transformInput link for " + model_id + " to " + cast_v2s(source[key]) + " while adding operation " + operation_name)
 				link = instantiate_link(core, "transformInput", "", model_id, source[key])
 				instantiate_attribute(core, link, "name", key)
 
@@ -1756,7 +1753,9 @@ String function cmd_transformation_add_MT(source_models : Element, target_models
 			return "Model not found: " + name!
 
 	merged_formalism = model_fuse(to_ramify)
+	model_create(merged_formalism, "merged/" + operation_name, get_entry_id("formalisms/SimpleClassDiagrams"), "Model")
 	modify(merged_formalism, True)
+	model_overwrite(merged_formalism, get_entry_id("merged/" + operation_name), get_entry_id("formalisms/SimpleClassDiagrams"))
 
 	ramified_metamodel = ramify(merged_formalism)
 	model_create(ramified_metamodel, "RAMified/" + operation_name, get_entry_id("formalisms/SimpleClassDiagrams"), "Model")
@@ -1794,7 +1793,6 @@ String function cmd_transformation_add_MT(source_models : Element, target_models
 		while (set_len(keys) > 0):
 			key = set_pop(keys)
 			dst = source[key]
-			log("Add transformInput link for " + model_id + " to " + dst + " while adding operation " + operation_name)
 			link = instantiate_link(core, "transformInput", "", model_id, dst)
 			instantiate_attribute(core, link, "name", key)