]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.modeling.ontology/graph/Switching.pgraph
(refs #7453) Switch component type of the component
[simantics/platform.git] / bundles / org.simantics.modeling.ontology / graph / Switching.pgraph
diff --git a/bundles/org.simantics.modeling.ontology/graph/Switching.pgraph b/bundles/org.simantics.modeling.ontology/graph/Switching.pgraph
new file mode 100644 (file)
index 0000000..0382e25
--- /dev/null
@@ -0,0 +1,20 @@
+L0 = <http://www.simantics.org/Layer0-1.1>
+STR = <http://www.simantics.org/Structural-1.2>
+MOD = <http://www.simantics.org/Modeling-1.2>
+
+MOD.ComponentSwitchGroup <T L0.Entity
+    // L0.HasLabel
+    >-- MOD.ComponentSwitchGroup.alternative --> MOD.ComponentSwitchAlternative <R L0.IsComposedOf
+
+MOD.ComponentSwitchAlternative <T L0.Entity
+    // L0.HasLabel
+    >-- MOD.ComponentSwitchAlternative.componentType --> STR.ComponentType <R L0.IsRelatedTo : L0.TotalFunction
+        L0.InverseOf MOD.BelongsToComponentSwitchGroup <R L0.IsRelatedTo
+
+MOD.ComponentSwitchAlternative.withLabel : L0.Template 
+    @template %group %label %componentType
+        %group
+            MOD.ComponentSwitchGroup.alternative _ : MOD.ComponentSwitchAlternative
+                L0.HasLabel %label
+                MOD.ComponentSwitchAlternative.componentType %componentType
+            
\ No newline at end of file