|
|
@@ -113,6 +113,9 @@ Element function create_metamodels():
|
|
|
//general lefthandside node (contains plabel for example)
|
|
|
instantiate_node(transform_metamodel, "Class", "RAMgeneral")
|
|
|
instantiate_named(transform_metamodel, "l5", "plabel", "RAMgeneral", "Integer")
|
|
|
+ instantiate_named(transform_metamodel, "l5", "function", "RAMgeneral", "String")
|
|
|
+ instantiate_named(transform_metamodel, "l5", "pivotIn", "RAMgeneral", "String")
|
|
|
+ instantiate_named(transform_metamodel, "l5", "pivotOut", "RAMgeneral", "String")
|
|
|
//connect RAMgeneral to precondition
|
|
|
instantiate_link(transform_metamodel, "l5", "pre2ram", "Precondition","RAMgeneral")
|
|
|
//connect RAMgeneral to postcondition
|
|
|
@@ -121,7 +124,7 @@ Element function create_metamodels():
|
|
|
//////////////////
|
|
|
// Variable part (this is were relaxed metamodels will be inserted )
|
|
|
// for the moment this means that we:
|
|
|
- // 1) copy the metamodel
|
|
|
+ // 1) copy the metamodel (without attributes)
|
|
|
// 2) Relaxation: ignore the constraints by simply not copying them (we will later on make a distinction in constraints that should or should not be respected)
|
|
|
// 3) Augmentation: insert for every element the plabel (now implemented by inheritance)
|
|
|
// 4) Modification: change attributes to string, so that python code can be inserted (later on, change to action code)
|
|
|
@@ -132,15 +135,12 @@ Element function create_metamodels():
|
|
|
//RAMified petrinet for left hand side
|
|
|
//place with tokens
|
|
|
instantiate_node(transform_metamodel, "Class", "Place_LHS")
|
|
|
- instantiate_named(transform_metamodel, "l5", "tokens", "Place_LHS", "String") //modification
|
|
|
//transition
|
|
|
instantiate_node(transform_metamodel, "Class", "Transition_LHS")
|
|
|
//P2T with weight
|
|
|
instantiate_link(transform_metamodel, "l5", "P2T_LHS", "Place_LHS","Transition_LHS")
|
|
|
- instantiate_named(transform_metamodel, "l5", "weight", "P2T_LHS", "String")
|
|
|
//T2P with weight
|
|
|
instantiate_link(transform_metamodel, "l5", "T2P_LHS", "Transition_LHS","Place_LHS")
|
|
|
- instantiate_named(transform_metamodel, "l5", "weight", "T2P_LHS", "String")
|
|
|
//inheritance links
|
|
|
instantiate_link(transform_metamodel, "inheritance", "Place_LHS_is_RAM", "Place_LHS","RAMgeneral")
|
|
|
instantiate_link(transform_metamodel, "inheritance", "Transition_LHS_is_RAM", "Transition_LHS","RAMgeneral")
|
|
|
@@ -149,12 +149,9 @@ Element function create_metamodels():
|
|
|
|
|
|
//RAMified petrinet for RIGHT hand side
|
|
|
instantiate_node(transform_metamodel, "Class", "Place_RHS")
|
|
|
- instantiate_named(transform_metamodel, "l5", "tokens", "Place_RHS", "String") //modification
|
|
|
instantiate_node(transform_metamodel, "Class", "Transition_RHS")
|
|
|
instantiate_link(transform_metamodel, "l5", "P2T_RHS", "Place_RHS","Transition_RHS")
|
|
|
- instantiate_named(transform_metamodel, "l5", "weight", "P2T_RHS", "String")
|
|
|
instantiate_link(transform_metamodel, "l5", "T2P_RHS", "Transition_RHS","Place_RHS")
|
|
|
- instantiate_named(transform_metamodel, "l5", "weight", "T2P_RHS", "String") //modification
|
|
|
//inheritance links
|
|
|
instantiate_link(transform_metamodel, "inheritance", "Place_RHS_is_RAM", "Place_RHS","RAMgeneral")
|
|
|
instantiate_link(transform_metamodel, "inheritance", "Transition_RHS_is_RAM", "Transition_RHS","RAMgeneral")
|