]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.modeling.ontology/graph/Typicals.pgraph
0250167df7befb1d27e5db72eee32c3acedb8928
[simantics/platform.git] / bundles / org.simantics.modeling.ontology / graph / Typicals.pgraph
1 L0 = <http://www.simantics.org/Layer0-1.1>\r
2 L0X = <http://www.simantics.org/Layer0X-1.1>\r
3 STR = <http://www.simantics.org/Structural-1.2>\r
4 G2D = <http://www.simantics.org/G2D-1.1>\r
5 DIA = <http://www.simantics.org/Diagram-2.2>\r
6 SIMU = <http://www.simantics.org/Simulation-1.1>\r
7 DOC = <http://www.simantics.org/Document-1.2>\r
8 ISSUE = <http://www.simantics.org/Issue-1.2>\r
9 SG = <http://www.simantics.org/Scenegraph-1.1>\r
10 MOD = <http://www.simantics.org/Modeling-1.2>\r
11 ACT = <http://www.simantics.org/Action-1.1>\r
12 \r
13 PRED = L0X.Predicate\r
14 \r
15 //##########################################################################
16 //## Actions
17 //##########################################################################
18 \r
19 MOD.NewMasterTypicalDiagram : ACT.Action\r
20 MOD.NewTypicalDiagramInstance : ACT.Action\r
21 \r
22 //##########################################################################\r
23 //## Concepts\r
24 //##########################################################################\r
25 \r
26 MOD.MasterTypicalCompositeType <T L0.Entity : MOD.TypeWithChangeInformation\r
27     L0.HasDescription "Indicates the original template instance of a typical composite. This is for searching purposes to differetiate typical template instances from linked copies of the template."\r
28 \r
29 MOD.TypicalComposite <T STR.Composite\r
30     L0.HasDescription "All typical composite types must inherit this base type."\r
31     >-- MOD.TypicalComposite.typicalNamingFunction --> L0.ExternalValue ==> "ReadGraph -> Resource -> Resource -> String -> String" <R L0.HasProperty : L0.FunctionalRelation\r
32 \r
33 // For associating typical diagram source and instance structures with each other\r
34 MOD.HasDiagramSource <R L0.IsRelatedTo\r
35     L0.InverseOf MOD.DiagramHasInstance <R L0.IsWeaklyRelatedTo\r
36     <-- DIA.Diagram --> DIA.Diagram\r
37 MOD.HasElementSource <R L0.IsRelatedTo\r
38     L0.InverseOf MOD.ElementHasInstance <R L0.IsWeaklyRelatedTo\r
39     <-- DIA.Element --> DIA.Element\r
40 \r
41 MOD.IsTemplatized\r
42     L0.HasDescription "A tag for marking elements of typical diagram template instances as being controlled by the template. These tags are used to identify elements that still exist in the instance but no longer in the template."\r
43     @L0.defTag\r
44     @L0.symmetric\r
45 \r
46 MOD.TypicalSynchronizationRule <T L0.Entity\r
47     L0.HasDescription "These entities shall be adaptable to interface org.simantics.modeling.typicals.ITypicalSynchronizationRule. They can be attached to diagram elements."\r
48     >-- MOD.TypicalSynchronizationRule.alwaysEnabled --> L0.Boolean <R L0.HasProperty : L0.FunctionalRelation\r
49         L0.HasDescription "When true, tells that a typical synchronization rule shall always be applied during synchronization and is not to be presented to the user for (de)selection."\r
50 \r
51 MOD.HasTypicalSynchronizationRule <R L0.IsRelatedTo\r
52     <-- DIA.Element\r
53     --> MOD.TypicalSynchronizationRule\r
54 \r
55 //##########################################################################\r
56 //## MOD.StructuralModel additions\r
57 //##########################################################################\r
58 \r
59 // Add typical diagram support\r
60 MOD.StructuralModel\r
61     // For creating new master typical diagrams\r
62     >-- MOD.StructuralModel.HasTypicalCompositeBaseType --> L0.Type <R L0.IsRelatedTo : L0.FunctionalRelation\r
63         L0.HasDescription """Defines the structural composite base type from which to inherit typical diagrams created in this type of model."""\r
64     >-- MOD.StructuralModel.HasTypicalDiagramBaseType --> L0.Type <R L0.IsRelatedTo : L0.FunctionalRelation\r
65         L0.HasDescription """Defines the structural diagram base type from which to inherit typical diagrams created in this type of model."""\r
66     >-- MOD.StructuralModel.HasMasterTypicalCompositeType --> L0.Type <R L0.IsRelatedTo : L0.FunctionalRelation\r
67         L0.HasDescription """Defines a secondary type that master typical composite shall inherit when created in this type of model. This type can be used for searching for all typical master diagrams."""\r
68     >-- MOD.StructuralModel.CloneTypicalDiagramSymbolContributionsFrom --> L0.Type <R L0.IsRelatedTo\r
69         L0.HasDescription """Defines diagram types to copy diagram symbol contributions from into newly created typical diagrams."""\r
70     >-- MOD.StructuralModel.typicalInstantiationFunction --> L0.ExternalValue ==> "Resource -> Resource -> Resource" <R L0.HasProperty : L0.FunctionalRelation\r
71 \r
72     @L0.assert MOD.StructuralModel.HasTypicalCompositeBaseType MOD.TypicalComposite\r
73     @L0.assert MOD.StructuralModel.HasMasterTypicalCompositeType MOD.MasterTypicalCompositeType\r
74     @L0.assert MOD.StructuralModel.typicalInstantiationFunction MOD.Functions.standardTypicalInstantiator\r
75 \r
76 MOD.Functions.standardTypicalInstantiator : L0.ExternalValue\r
77     L0.HasDescription "See org.simantics.modeling.ui.functions.All.standardTypicalInstantiator"