Browse Source

Some more explanation

Yentl Van Tendeloo 3 years ago
parent
commit
85151ec315
2 changed files with 9 additions and 7 deletions
  1. 8 6
      examples/multi_conformance.py
  2. 1 1
      wrappers/modelverse_SCCD.py

+ 8 - 6
examples/multi_conformance.py

@@ -65,9 +65,11 @@ model_add("models/model_integer", "formalisms/simple_mm", model_integer)
 transformation_add_AL({"model": "formalisms/Bottom", "metamodel": "formalisms/SimpleClassDiagrams", "type_mapping": "formalisms/TypeMapping"}, {}, "models/conformance_AToMPM", open("models/Conformance/AToMPM.alc", 'r').read())
 transformation_add_AL({"model": "formalisms/Bottom", "metamodel": "formalisms/SimpleClassDiagrams", "type_mapping": "formalisms/TypeMapping"}, {}, "models/conformance_MetaDepth", open("models/Conformance/MetaDepth.alc", 'r').read())
 
-print(model_types("models/model_string"))
-
-transformation_execute_AL("models/conformance_AToMPM", {"model": "models/model_integer", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_integer").pop()[1]}, {})
-transformation_execute_AL("models/conformance_AToMPM", {"model": "models/model_string", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_string").pop()[1]}, {})
-transformation_execute_AL("models/conformance_MetaDepth", {"model": "models/model_integer", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_integer").pop()[1]}, {})
-transformation_execute_AL("models/conformance_MetaDepth", {"model": "models/model_string", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_string").pop()[1]}, {})
+print("Checking conformance of model with Integer in AToMPM semantics:")
+print(transformation_execute_AL("models/conformance_AToMPM", {"model": "models/model_integer", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_integer").pop()[1]}, {}))
+print("Checking conformance of model with String in AToMPM semantics:")
+print(transformation_execute_AL("models/conformance_AToMPM", {"model": "models/model_string", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_string").pop()[1]}, {}))
+print("Checking conformance of model with Integer in MetaDepth semantics:")
+print(transformation_execute_AL("models/conformance_MetaDepth", {"model": "models/model_integer", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_integer").pop()[1]}, {}))
+print("Checking conformance of model with String in MetaDepth semantics:")
+print(transformation_execute_AL("models/conformance_MetaDepth", {"model": "models/model_string", "metamodel": "formalisms/simple_mm", "type_mapping": model_types("models/model_string").pop()[1]}, {}))

+ 1 - 1
wrappers/modelverse_SCCD.py

@@ -1,7 +1,7 @@
 """
 Generated by Statechart compiler by Glenn De Jonghe, Joeri Exelmans, Simon Van Mierlo, and Yentl Van Tendeloo (for the inspiration)
 
-Date:   Fri May 25 16:06:09 2018
+Date:   Fri May 25 16:14:54 2018
 
 Model author: Yentl Van Tendeloo
 Model name:   MvK Server