]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.diagram.ontology/graph/DiagramFlags.pgraph
Fixed multiple issues causing dangling references to discarded queries
[simantics/platform.git] / bundles / org.simantics.diagram.ontology / graph / DiagramFlags.pgraph
1 L0 = <http://www.simantics.org/Layer0-1.1>
2 STR = <http://www.simantics.org/Structural-1.2>
3 G2D = <http://www.simantics.org/G2D-1.1>
4 DIA = <http://www.simantics.org/Diagram-2.2>
5 SEL = <http://www.simantics.org/SelectionView-1.2>
6
7 DIA.HasFlagType <R L0.IsRelatedTo : L0.FunctionalRelation
8     L0.HasLabel "Flag Type"
9     --> DIA.FlagType
10
11 DIA.FlagType <T L0.Property
12     L0.HasDescription "Connection flag type (input or output)"
13     @L0.tag L0.Enumeration
14 DIA.FlagType.InputFlag : DIA.FlagType
15 DIA.FlagType.OutputFlag : DIA.FlagType
16
17 DIA.FlagLabel <T L0.String
18     L0.HasDescription "This specialized label type exists because we need to attach a custom StringModifier to it."
19
20 DIA.Flag <T DIA.DefinedElement
21     L0.HasDescription "Flags are used on diagrams for cutting connections and continuing them elsewhere."
22     @L0.singleProperty DIA.HasFlagType
23     @L0.property DIA.ExternalFlag
24     >-- DIA.Flag.HasIOTableBinding --> L0.String <R L0.HasProperty : L0.FunctionalRelation : SEL.GenericParameterType
25         L0.HasLabel "I/O Table Binding"
26     >-- DIA.Flag.HasIOTableRowIndex --> L0.Integer <R L0.HasProperty : L0.FunctionalRelation : SEL.GenericParameterType
27         L0.HasLabel "I/O Table Row Index"
28     @L0.assert DIA.Flag.HasIOTableRowIndex
29         -1 : L0.Integer
30     @L0.assert DIA.Flag.HasIOTableBinding
31         "" : L0.String
32     @L0.property DIA.FlagIsJoinedBy
33     @L0.optionalProperty L0.HasLabel
34     @L0.assert DIA.HasFlagType DIA.FlagType.InputFlag
35     @L0.assert L0.HasLabel
36         "" : DIA.FlagLabel
37     STR.IsDefinedBy _ : DIA.Composite
38         @L0.orderedSet
39             DIA.Flag.Terminal : DIA.Terminal
40                 DIA.HasTransform [1,0,0,1,0,0] : G2D.Transform
41                 DIA.HasConnectionPoint DIA.Flag.ConnectionPoint
42                     <-- DIA.Flag
43     @L0.assert DIA.HasDynamicTransform
44         DIA.Functions.flagTransform : L0.Function
45
46 DIA.Flag.ConnectionPoint <R STR.IsConnectedTo : L0.FunctionalRelation
47
48 DIA.ExternalFlag
49     @L0.defTag 
50     L0.HasDescription "Used for tagging flags as external flows. External flows cannot be continued on the same or other diagrams of the same model."
51     <-- DIA.Flag
52     --> DIA.Flag
53
54
55 DIA.JoinsFlag <R L0.IsRelatedTo 
56     L0.InverseOf DIA.FlagIsJoinedBy <R L0.IsRelatedTo
57         @L0.tag L0.SharedRange
58         <-- DIA.Flag
59         --> STR.ConnectionJoin
60
61 DIA.IsLiftedAs <R L0.IsRelatedTo : L0.FunctionalRelation
62     <-- DIA.Flag
63     --> STR.ConnectionRelation
64     L0.InverseOf DIA.Lifts <R L0.IsRelatedTo : L0.FunctionalRelation
65
66
67 //// Preferences for labeling diagram flags
68
69 DIA.UsesLocalFlagLabelingScheme <R L0.IsRelatedTo
70
71 DIA.FlagLabelingScheme <T L0.Entity
72     @L0.tag L0.Enumeration
73 DIA.FlagLabelingScheme.Alphabetical : DIA.FlagLabelingScheme
74     L0.HasLabel "Alphabetical"
75     L0.HasDescription "Alphabetical labeling scheme. A, B; C, ..., X, Y, Z, AA, AB, AC, ..."
76 DIA.FlagLabelingScheme.Numeric : DIA.FlagLabelingScheme
77     L0.HasLabel "Numeric"
78     L0.HasDescription "Numeric labeling scheme. 1, 2, 3, ..."