diff options
Diffstat (limited to 'org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org')
22 files changed, 660 insertions, 101 deletions
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Argument.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Argument.java index 5442f8e0..4857b38a 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Argument.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Argument.java | |||
@@ -13,7 +13,7 @@ import org.eclipse.emf.ecore.EObject; | |||
13 | * The following features are supported: | 13 | * The following features are supported: |
14 | * </p> | 14 | * </p> |
15 | * <ul> | 15 | * <ul> |
16 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.Argument#getVariable <em>Variable</em>}</li> | 16 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.Argument#getVariableOrNode <em>Variable Or Node</em>}</li> |
17 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.Argument#getSingletonVariable <em>Singleton Variable</em>}</li> | 17 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.Argument#getSingletonVariable <em>Singleton Variable</em>}</li> |
18 | * </ul> | 18 | * </ul> |
19 | * | 19 | * |
@@ -23,26 +23,26 @@ import org.eclipse.emf.ecore.EObject; | |||
23 | */ | 23 | */ |
24 | public interface Argument extends EObject { | 24 | public interface Argument extends EObject { |
25 | /** | 25 | /** |
26 | * Returns the value of the '<em><b>Variable</b></em>' reference. | 26 | * Returns the value of the '<em><b>Variable Or Node</b></em>' reference. |
27 | * <!-- begin-user-doc --> | 27 | * <!-- begin-user-doc --> |
28 | * <!-- end-user-doc --> | 28 | * <!-- end-user-doc --> |
29 | * @return the value of the '<em>Variable</em>' reference. | 29 | * @return the value of the '<em>Variable Or Node</em>' reference. |
30 | * @see #setVariable(Variable) | 30 | * @see #setVariableOrNode(VariableOrNode) |
31 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getArgument_Variable() | 31 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getArgument_VariableOrNode() |
32 | * @model | 32 | * @model |
33 | * @generated | 33 | * @generated |
34 | */ | 34 | */ |
35 | Variable getVariable(); | 35 | VariableOrNode getVariableOrNode(); |
36 | 36 | ||
37 | /** | 37 | /** |
38 | * Sets the value of the '{@link org.eclipse.viatra.solver.language.model.problem.Argument#getVariable <em>Variable</em>}' reference. | 38 | * Sets the value of the '{@link org.eclipse.viatra.solver.language.model.problem.Argument#getVariableOrNode <em>Variable Or Node</em>}' reference. |
39 | * <!-- begin-user-doc --> | 39 | * <!-- begin-user-doc --> |
40 | * <!-- end-user-doc --> | 40 | * <!-- end-user-doc --> |
41 | * @param value the new value of the '<em>Variable</em>' reference. | 41 | * @param value the new value of the '<em>Variable Or Node</em>' reference. |
42 | * @see #getVariable() | 42 | * @see #getVariableOrNode() |
43 | * @generated | 43 | * @generated |
44 | */ | 44 | */ |
45 | void setVariable(Variable value); | 45 | void setVariableOrNode(VariableOrNode value); |
46 | 46 | ||
47 | /** | 47 | /** |
48 | * Returns the value of the '<em><b>Singleton Variable</b></em>' containment reference. | 48 | * Returns the value of the '<em><b>Singleton Variable</b></em>' containment reference. |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ClassDeclaration.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ClassDeclaration.java index 1387575a..d0f471be 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ClassDeclaration.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ClassDeclaration.java | |||
@@ -48,7 +48,7 @@ public interface ClassDeclaration extends Relation, Statement { | |||
48 | 48 | ||
49 | /** | 49 | /** |
50 | * Returns the value of the '<em><b>Super Types</b></em>' reference list. | 50 | * Returns the value of the '<em><b>Super Types</b></em>' reference list. |
51 | * The list contents are of type {@link org.eclipse.viatra.solver.language.model.problem.ClassDeclaration}. | 51 | * The list contents are of type {@link org.eclipse.viatra.solver.language.model.problem.Relation}. |
52 | * <!-- begin-user-doc --> | 52 | * <!-- begin-user-doc --> |
53 | * <!-- end-user-doc --> | 53 | * <!-- end-user-doc --> |
54 | * @return the value of the '<em>Super Types</em>' reference list. | 54 | * @return the value of the '<em>Super Types</em>' reference list. |
@@ -56,7 +56,7 @@ public interface ClassDeclaration extends Relation, Statement { | |||
56 | * @model | 56 | * @model |
57 | * @generated | 57 | * @generated |
58 | */ | 58 | */ |
59 | EList<ClassDeclaration> getSuperTypes(); | 59 | EList<Relation> getSuperTypes(); |
60 | 60 | ||
61 | /** | 61 | /** |
62 | * Returns the value of the '<em><b>Reference Declarations</b></em>' containment reference list. | 62 | * Returns the value of the '<em><b>Reference Declarations</b></em>' containment reference list. |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/EnumDeclaration.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/EnumDeclaration.java new file mode 100644 index 00000000..81f2967d --- /dev/null +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/EnumDeclaration.java | |||
@@ -0,0 +1,36 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package org.eclipse.viatra.solver.language.model.problem; | ||
4 | |||
5 | import org.eclipse.emf.common.util.EList; | ||
6 | |||
7 | /** | ||
8 | * <!-- begin-user-doc --> | ||
9 | * A representation of the model object '<em><b>Enum Declaration</b></em>'. | ||
10 | * <!-- end-user-doc --> | ||
11 | * | ||
12 | * <p> | ||
13 | * The following features are supported: | ||
14 | * </p> | ||
15 | * <ul> | ||
16 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.EnumDeclaration#getLiterals <em>Literals</em>}</li> | ||
17 | * </ul> | ||
18 | * | ||
19 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getEnumDeclaration() | ||
20 | * @model | ||
21 | * @generated | ||
22 | */ | ||
23 | public interface EnumDeclaration extends Relation, Statement { | ||
24 | /** | ||
25 | * Returns the value of the '<em><b>Literals</b></em>' containment reference list. | ||
26 | * The list contents are of type {@link org.eclipse.viatra.solver.language.model.problem.Node}. | ||
27 | * <!-- begin-user-doc --> | ||
28 | * <!-- end-user-doc --> | ||
29 | * @return the value of the '<em>Literals</em>' containment reference list. | ||
30 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getEnumDeclaration_Literals() | ||
31 | * @model containment="true" | ||
32 | * @generated | ||
33 | */ | ||
34 | EList<Node> getLiterals(); | ||
35 | |||
36 | } // EnumDeclaration | ||
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Node.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Node.java index e6547083..3da08af3 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Node.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Node.java | |||
@@ -12,5 +12,5 @@ package org.eclipse.viatra.solver.language.model.problem; | |||
12 | * @model | 12 | * @model |
13 | * @generated | 13 | * @generated |
14 | */ | 14 | */ |
15 | public interface Node extends NamedElement { | 15 | public interface Node extends VariableOrNode { |
16 | } // Node | 16 | } // Node |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Parameter.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Parameter.java index 5ed8ac3c..7bedca1b 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Parameter.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Parameter.java | |||
@@ -24,12 +24,12 @@ public interface Parameter extends Variable { | |||
24 | * <!-- begin-user-doc --> | 24 | * <!-- begin-user-doc --> |
25 | * <!-- end-user-doc --> | 25 | * <!-- end-user-doc --> |
26 | * @return the value of the '<em>Parameter Type</em>' reference. | 26 | * @return the value of the '<em>Parameter Type</em>' reference. |
27 | * @see #setParameterType(ClassDeclaration) | 27 | * @see #setParameterType(Relation) |
28 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getParameter_ParameterType() | 28 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getParameter_ParameterType() |
29 | * @model | 29 | * @model |
30 | * @generated | 30 | * @generated |
31 | */ | 31 | */ |
32 | ClassDeclaration getParameterType(); | 32 | Relation getParameterType(); |
33 | 33 | ||
34 | /** | 34 | /** |
35 | * Sets the value of the '{@link org.eclipse.viatra.solver.language.model.problem.Parameter#getParameterType <em>Parameter Type</em>}' reference. | 35 | * Sets the value of the '{@link org.eclipse.viatra.solver.language.model.problem.Parameter#getParameterType <em>Parameter Type</em>}' reference. |
@@ -39,6 +39,6 @@ public interface Parameter extends Variable { | |||
39 | * @see #getParameterType() | 39 | * @see #getParameterType() |
40 | * @generated | 40 | * @generated |
41 | */ | 41 | */ |
42 | void setParameterType(ClassDeclaration value); | 42 | void setParameterType(Relation value); |
43 | 43 | ||
44 | } // Parameter | 44 | } // Parameter |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemFactory.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemFactory.java index bdfc326b..e4332d19 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemFactory.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemFactory.java | |||
@@ -175,6 +175,15 @@ public interface ProblemFactory extends EFactory { | |||
175 | Argument createArgument(); | 175 | Argument createArgument(); |
176 | 176 | ||
177 | /** | 177 | /** |
178 | * Returns a new object of class '<em>Enum Declaration</em>'. | ||
179 | * <!-- begin-user-doc --> | ||
180 | * <!-- end-user-doc --> | ||
181 | * @return a new object of class '<em>Enum Declaration</em>'. | ||
182 | * @generated | ||
183 | */ | ||
184 | EnumDeclaration createEnumDeclaration(); | ||
185 | |||
186 | /** | ||
178 | * Returns the package supported by this factory. | 187 | * Returns the package supported by this factory. |
179 | * <!-- begin-user-doc --> | 188 | * <!-- begin-user-doc --> |
180 | * <!-- end-user-doc --> | 189 | * <!-- end-user-doc --> |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemPackage.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemPackage.java index 1358eaeb..ec96501d 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemPackage.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ProblemPackage.java | |||
@@ -397,6 +397,43 @@ public interface ProblemPackage extends EPackage { | |||
397 | int PREDICATE_DEFINITION_OPERATION_COUNT = RELATION_OPERATION_COUNT + 0; | 397 | int PREDICATE_DEFINITION_OPERATION_COUNT = RELATION_OPERATION_COUNT + 0; |
398 | 398 | ||
399 | /** | 399 | /** |
400 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.VariableOrNodeImpl <em>Variable Or Node</em>}' class. | ||
401 | * <!-- begin-user-doc --> | ||
402 | * <!-- end-user-doc --> | ||
403 | * @see org.eclipse.viatra.solver.language.model.problem.impl.VariableOrNodeImpl | ||
404 | * @see org.eclipse.viatra.solver.language.model.problem.impl.ProblemPackageImpl#getVariableOrNode() | ||
405 | * @generated | ||
406 | */ | ||
407 | int VARIABLE_OR_NODE = 25; | ||
408 | |||
409 | /** | ||
410 | * The feature id for the '<em><b>Name</b></em>' attribute. | ||
411 | * <!-- begin-user-doc --> | ||
412 | * <!-- end-user-doc --> | ||
413 | * @generated | ||
414 | * @ordered | ||
415 | */ | ||
416 | int VARIABLE_OR_NODE__NAME = NAMED_ELEMENT__NAME; | ||
417 | |||
418 | /** | ||
419 | * The number of structural features of the '<em>Variable Or Node</em>' class. | ||
420 | * <!-- begin-user-doc --> | ||
421 | * <!-- end-user-doc --> | ||
422 | * @generated | ||
423 | * @ordered | ||
424 | */ | ||
425 | int VARIABLE_OR_NODE_FEATURE_COUNT = NAMED_ELEMENT_FEATURE_COUNT + 0; | ||
426 | |||
427 | /** | ||
428 | * The number of operations of the '<em>Variable Or Node</em>' class. | ||
429 | * <!-- begin-user-doc --> | ||
430 | * <!-- end-user-doc --> | ||
431 | * @generated | ||
432 | * @ordered | ||
433 | */ | ||
434 | int VARIABLE_OR_NODE_OPERATION_COUNT = NAMED_ELEMENT_OPERATION_COUNT + 0; | ||
435 | |||
436 | /** | ||
400 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.VariableImpl <em>Variable</em>}' class. | 437 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.VariableImpl <em>Variable</em>}' class. |
401 | * <!-- begin-user-doc --> | 438 | * <!-- begin-user-doc --> |
402 | * <!-- end-user-doc --> | 439 | * <!-- end-user-doc --> |
@@ -413,7 +450,7 @@ public interface ProblemPackage extends EPackage { | |||
413 | * @generated | 450 | * @generated |
414 | * @ordered | 451 | * @ordered |
415 | */ | 452 | */ |
416 | int VARIABLE__NAME = NAMED_ELEMENT__NAME; | 453 | int VARIABLE__NAME = VARIABLE_OR_NODE__NAME; |
417 | 454 | ||
418 | /** | 455 | /** |
419 | * The number of structural features of the '<em>Variable</em>' class. | 456 | * The number of structural features of the '<em>Variable</em>' class. |
@@ -422,7 +459,7 @@ public interface ProblemPackage extends EPackage { | |||
422 | * @generated | 459 | * @generated |
423 | * @ordered | 460 | * @ordered |
424 | */ | 461 | */ |
425 | int VARIABLE_FEATURE_COUNT = NAMED_ELEMENT_FEATURE_COUNT + 0; | 462 | int VARIABLE_FEATURE_COUNT = VARIABLE_OR_NODE_FEATURE_COUNT + 0; |
426 | 463 | ||
427 | /** | 464 | /** |
428 | * The number of operations of the '<em>Variable</em>' class. | 465 | * The number of operations of the '<em>Variable</em>' class. |
@@ -431,7 +468,7 @@ public interface ProblemPackage extends EPackage { | |||
431 | * @generated | 468 | * @generated |
432 | * @ordered | 469 | * @ordered |
433 | */ | 470 | */ |
434 | int VARIABLE_OPERATION_COUNT = NAMED_ELEMENT_OPERATION_COUNT + 0; | 471 | int VARIABLE_OPERATION_COUNT = VARIABLE_OR_NODE_OPERATION_COUNT + 0; |
435 | 472 | ||
436 | /** | 473 | /** |
437 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.ParameterImpl <em>Parameter</em>}' class. | 474 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.ParameterImpl <em>Parameter</em>}' class. |
@@ -828,7 +865,7 @@ public interface ProblemPackage extends EPackage { | |||
828 | * @generated | 865 | * @generated |
829 | * @ordered | 866 | * @ordered |
830 | */ | 867 | */ |
831 | int NODE__NAME = NAMED_ELEMENT__NAME; | 868 | int NODE__NAME = VARIABLE_OR_NODE__NAME; |
832 | 869 | ||
833 | /** | 870 | /** |
834 | * The number of structural features of the '<em>Node</em>' class. | 871 | * The number of structural features of the '<em>Node</em>' class. |
@@ -837,7 +874,7 @@ public interface ProblemPackage extends EPackage { | |||
837 | * @generated | 874 | * @generated |
838 | * @ordered | 875 | * @ordered |
839 | */ | 876 | */ |
840 | int NODE_FEATURE_COUNT = NAMED_ELEMENT_FEATURE_COUNT + 0; | 877 | int NODE_FEATURE_COUNT = VARIABLE_OR_NODE_FEATURE_COUNT + 0; |
841 | 878 | ||
842 | /** | 879 | /** |
843 | * The number of operations of the '<em>Node</em>' class. | 880 | * The number of operations of the '<em>Node</em>' class. |
@@ -846,7 +883,7 @@ public interface ProblemPackage extends EPackage { | |||
846 | * @generated | 883 | * @generated |
847 | * @ordered | 884 | * @ordered |
848 | */ | 885 | */ |
849 | int NODE_OPERATION_COUNT = NAMED_ELEMENT_OPERATION_COUNT + 0; | 886 | int NODE_OPERATION_COUNT = VARIABLE_OR_NODE_OPERATION_COUNT + 0; |
850 | 887 | ||
851 | /** | 888 | /** |
852 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.ScopeDeclarationImpl <em>Scope Declaration</em>}' class. | 889 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.ScopeDeclarationImpl <em>Scope Declaration</em>}' class. |
@@ -1090,13 +1127,13 @@ public interface ProblemPackage extends EPackage { | |||
1090 | int ARGUMENT = 23; | 1127 | int ARGUMENT = 23; |
1091 | 1128 | ||
1092 | /** | 1129 | /** |
1093 | * The feature id for the '<em><b>Variable</b></em>' reference. | 1130 | * The feature id for the '<em><b>Variable Or Node</b></em>' reference. |
1094 | * <!-- begin-user-doc --> | 1131 | * <!-- begin-user-doc --> |
1095 | * <!-- end-user-doc --> | 1132 | * <!-- end-user-doc --> |
1096 | * @generated | 1133 | * @generated |
1097 | * @ordered | 1134 | * @ordered |
1098 | */ | 1135 | */ |
1099 | int ARGUMENT__VARIABLE = 0; | 1136 | int ARGUMENT__VARIABLE_OR_NODE = 0; |
1100 | 1137 | ||
1101 | /** | 1138 | /** |
1102 | * The feature id for the '<em><b>Singleton Variable</b></em>' containment reference. | 1139 | * The feature id for the '<em><b>Singleton Variable</b></em>' containment reference. |
@@ -1126,6 +1163,52 @@ public interface ProblemPackage extends EPackage { | |||
1126 | int ARGUMENT_OPERATION_COUNT = 0; | 1163 | int ARGUMENT_OPERATION_COUNT = 0; |
1127 | 1164 | ||
1128 | /** | 1165 | /** |
1166 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.EnumDeclarationImpl <em>Enum Declaration</em>}' class. | ||
1167 | * <!-- begin-user-doc --> | ||
1168 | * <!-- end-user-doc --> | ||
1169 | * @see org.eclipse.viatra.solver.language.model.problem.impl.EnumDeclarationImpl | ||
1170 | * @see org.eclipse.viatra.solver.language.model.problem.impl.ProblemPackageImpl#getEnumDeclaration() | ||
1171 | * @generated | ||
1172 | */ | ||
1173 | int ENUM_DECLARATION = 24; | ||
1174 | |||
1175 | /** | ||
1176 | * The feature id for the '<em><b>Name</b></em>' attribute. | ||
1177 | * <!-- begin-user-doc --> | ||
1178 | * <!-- end-user-doc --> | ||
1179 | * @generated | ||
1180 | * @ordered | ||
1181 | */ | ||
1182 | int ENUM_DECLARATION__NAME = RELATION__NAME; | ||
1183 | |||
1184 | /** | ||
1185 | * The feature id for the '<em><b>Literals</b></em>' containment reference list. | ||
1186 | * <!-- begin-user-doc --> | ||
1187 | * <!-- end-user-doc --> | ||
1188 | * @generated | ||
1189 | * @ordered | ||
1190 | */ | ||
1191 | int ENUM_DECLARATION__LITERALS = RELATION_FEATURE_COUNT + 0; | ||
1192 | |||
1193 | /** | ||
1194 | * The number of structural features of the '<em>Enum Declaration</em>' class. | ||
1195 | * <!-- begin-user-doc --> | ||
1196 | * <!-- end-user-doc --> | ||
1197 | * @generated | ||
1198 | * @ordered | ||
1199 | */ | ||
1200 | int ENUM_DECLARATION_FEATURE_COUNT = RELATION_FEATURE_COUNT + 1; | ||
1201 | |||
1202 | /** | ||
1203 | * The number of operations of the '<em>Enum Declaration</em>' class. | ||
1204 | * <!-- begin-user-doc --> | ||
1205 | * <!-- end-user-doc --> | ||
1206 | * @generated | ||
1207 | * @ordered | ||
1208 | */ | ||
1209 | int ENUM_DECLARATION_OPERATION_COUNT = RELATION_OPERATION_COUNT + 0; | ||
1210 | |||
1211 | /** | ||
1129 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.LogicValue <em>Logic Value</em>}' enum. | 1212 | * The meta object id for the '{@link org.eclipse.viatra.solver.language.model.problem.LogicValue <em>Logic Value</em>}' enum. |
1130 | * <!-- begin-user-doc --> | 1213 | * <!-- begin-user-doc --> |
1131 | * <!-- end-user-doc --> | 1214 | * <!-- end-user-doc --> |
@@ -1133,7 +1216,7 @@ public interface ProblemPackage extends EPackage { | |||
1133 | * @see org.eclipse.viatra.solver.language.model.problem.impl.ProblemPackageImpl#getLogicValue() | 1216 | * @see org.eclipse.viatra.solver.language.model.problem.impl.ProblemPackageImpl#getLogicValue() |
1134 | * @generated | 1217 | * @generated |
1135 | */ | 1218 | */ |
1136 | int LOGIC_VALUE = 24; | 1219 | int LOGIC_VALUE = 26; |
1137 | 1220 | ||
1138 | /** | 1221 | /** |
1139 | * Returns the meta object for class '{@link org.eclipse.viatra.solver.language.model.problem.Problem <em>Problem</em>}'. | 1222 | * Returns the meta object for class '{@link org.eclipse.viatra.solver.language.model.problem.Problem <em>Problem</em>}'. |
@@ -1717,15 +1800,15 @@ public interface ProblemPackage extends EPackage { | |||
1717 | EClass getArgument(); | 1800 | EClass getArgument(); |
1718 | 1801 | ||
1719 | /** | 1802 | /** |
1720 | * Returns the meta object for the reference '{@link org.eclipse.viatra.solver.language.model.problem.Argument#getVariable <em>Variable</em>}'. | 1803 | * Returns the meta object for the reference '{@link org.eclipse.viatra.solver.language.model.problem.Argument#getVariableOrNode <em>Variable Or Node</em>}'. |
1721 | * <!-- begin-user-doc --> | 1804 | * <!-- begin-user-doc --> |
1722 | * <!-- end-user-doc --> | 1805 | * <!-- end-user-doc --> |
1723 | * @return the meta object for the reference '<em>Variable</em>'. | 1806 | * @return the meta object for the reference '<em>Variable Or Node</em>'. |
1724 | * @see org.eclipse.viatra.solver.language.model.problem.Argument#getVariable() | 1807 | * @see org.eclipse.viatra.solver.language.model.problem.Argument#getVariableOrNode() |
1725 | * @see #getArgument() | 1808 | * @see #getArgument() |
1726 | * @generated | 1809 | * @generated |
1727 | */ | 1810 | */ |
1728 | EReference getArgument_Variable(); | 1811 | EReference getArgument_VariableOrNode(); |
1729 | 1812 | ||
1730 | /** | 1813 | /** |
1731 | * Returns the meta object for the containment reference '{@link org.eclipse.viatra.solver.language.model.problem.Argument#getSingletonVariable <em>Singleton Variable</em>}'. | 1814 | * Returns the meta object for the containment reference '{@link org.eclipse.viatra.solver.language.model.problem.Argument#getSingletonVariable <em>Singleton Variable</em>}'. |
@@ -1739,6 +1822,37 @@ public interface ProblemPackage extends EPackage { | |||
1739 | EReference getArgument_SingletonVariable(); | 1822 | EReference getArgument_SingletonVariable(); |
1740 | 1823 | ||
1741 | /** | 1824 | /** |
1825 | * Returns the meta object for class '{@link org.eclipse.viatra.solver.language.model.problem.EnumDeclaration <em>Enum Declaration</em>}'. | ||
1826 | * <!-- begin-user-doc --> | ||
1827 | * <!-- end-user-doc --> | ||
1828 | * @return the meta object for class '<em>Enum Declaration</em>'. | ||
1829 | * @see org.eclipse.viatra.solver.language.model.problem.EnumDeclaration | ||
1830 | * @generated | ||
1831 | */ | ||
1832 | EClass getEnumDeclaration(); | ||
1833 | |||
1834 | /** | ||
1835 | * Returns the meta object for the containment reference list '{@link org.eclipse.viatra.solver.language.model.problem.EnumDeclaration#getLiterals <em>Literals</em>}'. | ||
1836 | * <!-- begin-user-doc --> | ||
1837 | * <!-- end-user-doc --> | ||
1838 | * @return the meta object for the containment reference list '<em>Literals</em>'. | ||
1839 | * @see org.eclipse.viatra.solver.language.model.problem.EnumDeclaration#getLiterals() | ||
1840 | * @see #getEnumDeclaration() | ||
1841 | * @generated | ||
1842 | */ | ||
1843 | EReference getEnumDeclaration_Literals(); | ||
1844 | |||
1845 | /** | ||
1846 | * Returns the meta object for class '{@link org.eclipse.viatra.solver.language.model.problem.VariableOrNode <em>Variable Or Node</em>}'. | ||
1847 | * <!-- begin-user-doc --> | ||
1848 | * <!-- end-user-doc --> | ||
1849 | * @return the meta object for class '<em>Variable Or Node</em>'. | ||
1850 | * @see org.eclipse.viatra.solver.language.model.problem.VariableOrNode | ||
1851 | * @generated | ||
1852 | */ | ||
1853 | EClass getVariableOrNode(); | ||
1854 | |||
1855 | /** | ||
1742 | * Returns the meta object for enum '{@link org.eclipse.viatra.solver.language.model.problem.LogicValue <em>Logic Value</em>}'. | 1856 | * Returns the meta object for enum '{@link org.eclipse.viatra.solver.language.model.problem.LogicValue <em>Logic Value</em>}'. |
1743 | * <!-- begin-user-doc --> | 1857 | * <!-- begin-user-doc --> |
1744 | * <!-- end-user-doc --> | 1858 | * <!-- end-user-doc --> |
@@ -2260,12 +2374,12 @@ public interface ProblemPackage extends EPackage { | |||
2260 | EClass ARGUMENT = eINSTANCE.getArgument(); | 2374 | EClass ARGUMENT = eINSTANCE.getArgument(); |
2261 | 2375 | ||
2262 | /** | 2376 | /** |
2263 | * The meta object literal for the '<em><b>Variable</b></em>' reference feature. | 2377 | * The meta object literal for the '<em><b>Variable Or Node</b></em>' reference feature. |
2264 | * <!-- begin-user-doc --> | 2378 | * <!-- begin-user-doc --> |
2265 | * <!-- end-user-doc --> | 2379 | * <!-- end-user-doc --> |
2266 | * @generated | 2380 | * @generated |
2267 | */ | 2381 | */ |
2268 | EReference ARGUMENT__VARIABLE = eINSTANCE.getArgument_Variable(); | 2382 | EReference ARGUMENT__VARIABLE_OR_NODE = eINSTANCE.getArgument_VariableOrNode(); |
2269 | 2383 | ||
2270 | /** | 2384 | /** |
2271 | * The meta object literal for the '<em><b>Singleton Variable</b></em>' containment reference feature. | 2385 | * The meta object literal for the '<em><b>Singleton Variable</b></em>' containment reference feature. |
@@ -2276,6 +2390,34 @@ public interface ProblemPackage extends EPackage { | |||
2276 | EReference ARGUMENT__SINGLETON_VARIABLE = eINSTANCE.getArgument_SingletonVariable(); | 2390 | EReference ARGUMENT__SINGLETON_VARIABLE = eINSTANCE.getArgument_SingletonVariable(); |
2277 | 2391 | ||
2278 | /** | 2392 | /** |
2393 | * The meta object literal for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.EnumDeclarationImpl <em>Enum Declaration</em>}' class. | ||
2394 | * <!-- begin-user-doc --> | ||
2395 | * <!-- end-user-doc --> | ||
2396 | * @see org.eclipse.viatra.solver.language.model.problem.impl.EnumDeclarationImpl | ||
2397 | * @see org.eclipse.viatra.solver.language.model.problem.impl.ProblemPackageImpl#getEnumDeclaration() | ||
2398 | * @generated | ||
2399 | */ | ||
2400 | EClass ENUM_DECLARATION = eINSTANCE.getEnumDeclaration(); | ||
2401 | |||
2402 | /** | ||
2403 | * The meta object literal for the '<em><b>Literals</b></em>' containment reference list feature. | ||
2404 | * <!-- begin-user-doc --> | ||
2405 | * <!-- end-user-doc --> | ||
2406 | * @generated | ||
2407 | */ | ||
2408 | EReference ENUM_DECLARATION__LITERALS = eINSTANCE.getEnumDeclaration_Literals(); | ||
2409 | |||
2410 | /** | ||
2411 | * The meta object literal for the '{@link org.eclipse.viatra.solver.language.model.problem.impl.VariableOrNodeImpl <em>Variable Or Node</em>}' class. | ||
2412 | * <!-- begin-user-doc --> | ||
2413 | * <!-- end-user-doc --> | ||
2414 | * @see org.eclipse.viatra.solver.language.model.problem.impl.VariableOrNodeImpl | ||
2415 | * @see org.eclipse.viatra.solver.language.model.problem.impl.ProblemPackageImpl#getVariableOrNode() | ||
2416 | * @generated | ||
2417 | */ | ||
2418 | EClass VARIABLE_OR_NODE = eINSTANCE.getVariableOrNode(); | ||
2419 | |||
2420 | /** | ||
2279 | * The meta object literal for the '{@link org.eclipse.viatra.solver.language.model.problem.LogicValue <em>Logic Value</em>}' enum. | 2421 | * The meta object literal for the '{@link org.eclipse.viatra.solver.language.model.problem.LogicValue <em>Logic Value</em>}' enum. |
2280 | * <!-- begin-user-doc --> | 2422 | * <!-- begin-user-doc --> |
2281 | * <!-- end-user-doc --> | 2423 | * <!-- end-user-doc --> |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ReferenceDeclaration.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ReferenceDeclaration.java index f07ee7d1..38650d66 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ReferenceDeclaration.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/ReferenceDeclaration.java | |||
@@ -27,12 +27,12 @@ public interface ReferenceDeclaration extends Relation { | |||
27 | * <!-- begin-user-doc --> | 27 | * <!-- begin-user-doc --> |
28 | * <!-- end-user-doc --> | 28 | * <!-- end-user-doc --> |
29 | * @return the value of the '<em>Reference Type</em>' reference. | 29 | * @return the value of the '<em>Reference Type</em>' reference. |
30 | * @see #setReferenceType(ClassDeclaration) | 30 | * @see #setReferenceType(Relation) |
31 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getReferenceDeclaration_ReferenceType() | 31 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getReferenceDeclaration_ReferenceType() |
32 | * @model | 32 | * @model |
33 | * @generated | 33 | * @generated |
34 | */ | 34 | */ |
35 | ClassDeclaration getReferenceType(); | 35 | Relation getReferenceType(); |
36 | 36 | ||
37 | /** | 37 | /** |
38 | * Sets the value of the '{@link org.eclipse.viatra.solver.language.model.problem.ReferenceDeclaration#getReferenceType <em>Reference Type</em>}' reference. | 38 | * Sets the value of the '{@link org.eclipse.viatra.solver.language.model.problem.ReferenceDeclaration#getReferenceType <em>Reference Type</em>}' reference. |
@@ -42,7 +42,7 @@ public interface ReferenceDeclaration extends Relation { | |||
42 | * @see #getReferenceType() | 42 | * @see #getReferenceType() |
43 | * @generated | 43 | * @generated |
44 | */ | 44 | */ |
45 | void setReferenceType(ClassDeclaration value); | 45 | void setReferenceType(Relation value); |
46 | 46 | ||
47 | /** | 47 | /** |
48 | * Returns the value of the '<em><b>Opposite</b></em>' reference. | 48 | * Returns the value of the '<em><b>Opposite</b></em>' reference. |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Variable.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Variable.java index 26637a35..cba5740c 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Variable.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/Variable.java | |||
@@ -12,5 +12,5 @@ package org.eclipse.viatra.solver.language.model.problem; | |||
12 | * @model abstract="true" | 12 | * @model abstract="true" |
13 | * @generated | 13 | * @generated |
14 | */ | 14 | */ |
15 | public interface Variable extends NamedElement { | 15 | public interface Variable extends VariableOrNode { |
16 | } // Variable | 16 | } // Variable |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/VariableOrNode.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/VariableOrNode.java new file mode 100644 index 00000000..65c315e2 --- /dev/null +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/VariableOrNode.java | |||
@@ -0,0 +1,16 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package org.eclipse.viatra.solver.language.model.problem; | ||
4 | |||
5 | /** | ||
6 | * <!-- begin-user-doc --> | ||
7 | * A representation of the model object '<em><b>Variable Or Node</b></em>'. | ||
8 | * <!-- end-user-doc --> | ||
9 | * | ||
10 | * | ||
11 | * @see org.eclipse.viatra.solver.language.model.problem.ProblemPackage#getVariableOrNode() | ||
12 | * @model abstract="true" | ||
13 | * @generated | ||
14 | */ | ||
15 | public interface VariableOrNode extends NamedElement { | ||
16 | } // VariableOrNode | ||
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ArgumentImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ArgumentImpl.java index 9f6bc7ae..f7d045ca 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ArgumentImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ArgumentImpl.java | |||
@@ -14,7 +14,7 @@ import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | |||
14 | import org.eclipse.viatra.solver.language.model.problem.Argument; | 14 | import org.eclipse.viatra.solver.language.model.problem.Argument; |
15 | import org.eclipse.viatra.solver.language.model.problem.ImplicitVariable; | 15 | import org.eclipse.viatra.solver.language.model.problem.ImplicitVariable; |
16 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | 16 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; |
17 | import org.eclipse.viatra.solver.language.model.problem.Variable; | 17 | import org.eclipse.viatra.solver.language.model.problem.VariableOrNode; |
18 | 18 | ||
19 | /** | 19 | /** |
20 | * <!-- begin-user-doc --> | 20 | * <!-- begin-user-doc --> |
@@ -24,7 +24,7 @@ import org.eclipse.viatra.solver.language.model.problem.Variable; | |||
24 | * The following features are implemented: | 24 | * The following features are implemented: |
25 | * </p> | 25 | * </p> |
26 | * <ul> | 26 | * <ul> |
27 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.impl.ArgumentImpl#getVariable <em>Variable</em>}</li> | 27 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.impl.ArgumentImpl#getVariableOrNode <em>Variable Or Node</em>}</li> |
28 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.impl.ArgumentImpl#getSingletonVariable <em>Singleton Variable</em>}</li> | 28 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.impl.ArgumentImpl#getSingletonVariable <em>Singleton Variable</em>}</li> |
29 | * </ul> | 29 | * </ul> |
30 | * | 30 | * |
@@ -32,14 +32,14 @@ import org.eclipse.viatra.solver.language.model.problem.Variable; | |||
32 | */ | 32 | */ |
33 | public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argument { | 33 | public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argument { |
34 | /** | 34 | /** |
35 | * The cached value of the '{@link #getVariable() <em>Variable</em>}' reference. | 35 | * The cached value of the '{@link #getVariableOrNode() <em>Variable Or Node</em>}' reference. |
36 | * <!-- begin-user-doc --> | 36 | * <!-- begin-user-doc --> |
37 | * <!-- end-user-doc --> | 37 | * <!-- end-user-doc --> |
38 | * @see #getVariable() | 38 | * @see #getVariableOrNode() |
39 | * @generated | 39 | * @generated |
40 | * @ordered | 40 | * @ordered |
41 | */ | 41 | */ |
42 | protected Variable variable; | 42 | protected VariableOrNode variableOrNode; |
43 | 43 | ||
44 | /** | 44 | /** |
45 | * The cached value of the '{@link #getSingletonVariable() <em>Singleton Variable</em>}' containment reference. | 45 | * The cached value of the '{@link #getSingletonVariable() <em>Singleton Variable</em>}' containment reference. |
@@ -75,17 +75,17 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
75 | * <!-- end-user-doc --> | 75 | * <!-- end-user-doc --> |
76 | * @generated | 76 | * @generated |
77 | */ | 77 | */ |
78 | public Variable getVariable() { | 78 | public VariableOrNode getVariableOrNode() { |
79 | if (variable != null && variable.eIsProxy()) { | 79 | if (variableOrNode != null && variableOrNode.eIsProxy()) { |
80 | InternalEObject oldVariable = (InternalEObject) variable; | 80 | InternalEObject oldVariableOrNode = (InternalEObject) variableOrNode; |
81 | variable = (Variable) eResolveProxy(oldVariable); | 81 | variableOrNode = (VariableOrNode) eResolveProxy(oldVariableOrNode); |
82 | if (variable != oldVariable) { | 82 | if (variableOrNode != oldVariableOrNode) { |
83 | if (eNotificationRequired()) | 83 | if (eNotificationRequired()) |
84 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, ProblemPackage.ARGUMENT__VARIABLE, | 84 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, ProblemPackage.ARGUMENT__VARIABLE_OR_NODE, |
85 | oldVariable, variable)); | 85 | oldVariableOrNode, variableOrNode)); |
86 | } | 86 | } |
87 | } | 87 | } |
88 | return variable; | 88 | return variableOrNode; |
89 | } | 89 | } |
90 | 90 | ||
91 | /** | 91 | /** |
@@ -93,8 +93,8 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
93 | * <!-- end-user-doc --> | 93 | * <!-- end-user-doc --> |
94 | * @generated | 94 | * @generated |
95 | */ | 95 | */ |
96 | public Variable basicGetVariable() { | 96 | public VariableOrNode basicGetVariableOrNode() { |
97 | return variable; | 97 | return variableOrNode; |
98 | } | 98 | } |
99 | 99 | ||
100 | /** | 100 | /** |
@@ -102,12 +102,12 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
102 | * <!-- end-user-doc --> | 102 | * <!-- end-user-doc --> |
103 | * @generated | 103 | * @generated |
104 | */ | 104 | */ |
105 | public void setVariable(Variable newVariable) { | 105 | public void setVariableOrNode(VariableOrNode newVariableOrNode) { |
106 | Variable oldVariable = variable; | 106 | VariableOrNode oldVariableOrNode = variableOrNode; |
107 | variable = newVariable; | 107 | variableOrNode = newVariableOrNode; |
108 | if (eNotificationRequired()) | 108 | if (eNotificationRequired()) |
109 | eNotify(new ENotificationImpl(this, Notification.SET, ProblemPackage.ARGUMENT__VARIABLE, oldVariable, | 109 | eNotify(new ENotificationImpl(this, Notification.SET, ProblemPackage.ARGUMENT__VARIABLE_OR_NODE, |
110 | variable)); | 110 | oldVariableOrNode, variableOrNode)); |
111 | } | 111 | } |
112 | 112 | ||
113 | /** | 113 | /** |
@@ -182,10 +182,10 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
182 | @Override | 182 | @Override |
183 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | 183 | public Object eGet(int featureID, boolean resolve, boolean coreType) { |
184 | switch (featureID) { | 184 | switch (featureID) { |
185 | case ProblemPackage.ARGUMENT__VARIABLE: | 185 | case ProblemPackage.ARGUMENT__VARIABLE_OR_NODE: |
186 | if (resolve) | 186 | if (resolve) |
187 | return getVariable(); | 187 | return getVariableOrNode(); |
188 | return basicGetVariable(); | 188 | return basicGetVariableOrNode(); |
189 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: | 189 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: |
190 | return getSingletonVariable(); | 190 | return getSingletonVariable(); |
191 | } | 191 | } |
@@ -200,8 +200,8 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
200 | @Override | 200 | @Override |
201 | public void eSet(int featureID, Object newValue) { | 201 | public void eSet(int featureID, Object newValue) { |
202 | switch (featureID) { | 202 | switch (featureID) { |
203 | case ProblemPackage.ARGUMENT__VARIABLE: | 203 | case ProblemPackage.ARGUMENT__VARIABLE_OR_NODE: |
204 | setVariable((Variable) newValue); | 204 | setVariableOrNode((VariableOrNode) newValue); |
205 | return; | 205 | return; |
206 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: | 206 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: |
207 | setSingletonVariable((ImplicitVariable) newValue); | 207 | setSingletonVariable((ImplicitVariable) newValue); |
@@ -218,8 +218,8 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
218 | @Override | 218 | @Override |
219 | public void eUnset(int featureID) { | 219 | public void eUnset(int featureID) { |
220 | switch (featureID) { | 220 | switch (featureID) { |
221 | case ProblemPackage.ARGUMENT__VARIABLE: | 221 | case ProblemPackage.ARGUMENT__VARIABLE_OR_NODE: |
222 | setVariable((Variable) null); | 222 | setVariableOrNode((VariableOrNode) null); |
223 | return; | 223 | return; |
224 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: | 224 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: |
225 | setSingletonVariable((ImplicitVariable) null); | 225 | setSingletonVariable((ImplicitVariable) null); |
@@ -236,8 +236,8 @@ public class ArgumentImpl extends MinimalEObjectImpl.Container implements Argume | |||
236 | @Override | 236 | @Override |
237 | public boolean eIsSet(int featureID) { | 237 | public boolean eIsSet(int featureID) { |
238 | switch (featureID) { | 238 | switch (featureID) { |
239 | case ProblemPackage.ARGUMENT__VARIABLE: | 239 | case ProblemPackage.ARGUMENT__VARIABLE_OR_NODE: |
240 | return variable != null; | 240 | return variableOrNode != null; |
241 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: | 241 | case ProblemPackage.ARGUMENT__SINGLETON_VARIABLE: |
242 | return singletonVariable != null; | 242 | return singletonVariable != null; |
243 | } | 243 | } |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ClassDeclarationImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ClassDeclarationImpl.java index 89de4d01..774a6e33 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ClassDeclarationImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ClassDeclarationImpl.java | |||
@@ -22,6 +22,7 @@ import org.eclipse.viatra.solver.language.model.problem.ClassDeclaration; | |||
22 | import org.eclipse.viatra.solver.language.model.problem.Node; | 22 | import org.eclipse.viatra.solver.language.model.problem.Node; |
23 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | 23 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; |
24 | import org.eclipse.viatra.solver.language.model.problem.ReferenceDeclaration; | 24 | import org.eclipse.viatra.solver.language.model.problem.ReferenceDeclaration; |
25 | import org.eclipse.viatra.solver.language.model.problem.Relation; | ||
25 | 26 | ||
26 | /** | 27 | /** |
27 | * <!-- begin-user-doc --> | 28 | * <!-- begin-user-doc --> |
@@ -68,7 +69,7 @@ public class ClassDeclarationImpl extends RelationImpl implements ClassDeclarati | |||
68 | * @generated | 69 | * @generated |
69 | * @ordered | 70 | * @ordered |
70 | */ | 71 | */ |
71 | protected EList<ClassDeclaration> superTypes; | 72 | protected EList<Relation> superTypes; |
72 | 73 | ||
73 | /** | 74 | /** |
74 | * The cached value of the '{@link #getReferenceDeclarations() <em>Reference Declarations</em>}' containment reference list. | 75 | * The cached value of the '{@link #getReferenceDeclarations() <em>Reference Declarations</em>}' containment reference list. |
@@ -136,9 +137,9 @@ public class ClassDeclarationImpl extends RelationImpl implements ClassDeclarati | |||
136 | * <!-- end-user-doc --> | 137 | * <!-- end-user-doc --> |
137 | * @generated | 138 | * @generated |
138 | */ | 139 | */ |
139 | public EList<ClassDeclaration> getSuperTypes() { | 140 | public EList<Relation> getSuperTypes() { |
140 | if (superTypes == null) { | 141 | if (superTypes == null) { |
141 | superTypes = new EObjectResolvingEList<ClassDeclaration>(ClassDeclaration.class, this, | 142 | superTypes = new EObjectResolvingEList<Relation>(Relation.class, this, |
142 | ProblemPackage.CLASS_DECLARATION__SUPER_TYPES); | 143 | ProblemPackage.CLASS_DECLARATION__SUPER_TYPES); |
143 | } | 144 | } |
144 | return superTypes; | 145 | return superTypes; |
@@ -257,7 +258,7 @@ public class ClassDeclarationImpl extends RelationImpl implements ClassDeclarati | |||
257 | return; | 258 | return; |
258 | case ProblemPackage.CLASS_DECLARATION__SUPER_TYPES: | 259 | case ProblemPackage.CLASS_DECLARATION__SUPER_TYPES: |
259 | getSuperTypes().clear(); | 260 | getSuperTypes().clear(); |
260 | getSuperTypes().addAll((Collection<? extends ClassDeclaration>) newValue); | 261 | getSuperTypes().addAll((Collection<? extends Relation>) newValue); |
261 | return; | 262 | return; |
262 | case ProblemPackage.CLASS_DECLARATION__REFERENCE_DECLARATIONS: | 263 | case ProblemPackage.CLASS_DECLARATION__REFERENCE_DECLARATIONS: |
263 | getReferenceDeclarations().clear(); | 264 | getReferenceDeclarations().clear(); |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/EnumDeclarationImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/EnumDeclarationImpl.java new file mode 100644 index 00000000..aac00423 --- /dev/null +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/EnumDeclarationImpl.java | |||
@@ -0,0 +1,150 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package org.eclipse.viatra.solver.language.model.problem.impl; | ||
4 | |||
5 | import java.util.Collection; | ||
6 | |||
7 | import org.eclipse.emf.common.notify.NotificationChain; | ||
8 | |||
9 | import org.eclipse.emf.common.util.EList; | ||
10 | |||
11 | import org.eclipse.emf.ecore.EClass; | ||
12 | import org.eclipse.emf.ecore.InternalEObject; | ||
13 | |||
14 | import org.eclipse.emf.ecore.util.EObjectContainmentEList; | ||
15 | import org.eclipse.emf.ecore.util.InternalEList; | ||
16 | |||
17 | import org.eclipse.viatra.solver.language.model.problem.EnumDeclaration; | ||
18 | import org.eclipse.viatra.solver.language.model.problem.Node; | ||
19 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | ||
20 | |||
21 | /** | ||
22 | * <!-- begin-user-doc --> | ||
23 | * An implementation of the model object '<em><b>Enum Declaration</b></em>'. | ||
24 | * <!-- end-user-doc --> | ||
25 | * <p> | ||
26 | * The following features are implemented: | ||
27 | * </p> | ||
28 | * <ul> | ||
29 | * <li>{@link org.eclipse.viatra.solver.language.model.problem.impl.EnumDeclarationImpl#getLiterals <em>Literals</em>}</li> | ||
30 | * </ul> | ||
31 | * | ||
32 | * @generated | ||
33 | */ | ||
34 | public class EnumDeclarationImpl extends RelationImpl implements EnumDeclaration { | ||
35 | /** | ||
36 | * The cached value of the '{@link #getLiterals() <em>Literals</em>}' containment reference list. | ||
37 | * <!-- begin-user-doc --> | ||
38 | * <!-- end-user-doc --> | ||
39 | * @see #getLiterals() | ||
40 | * @generated | ||
41 | * @ordered | ||
42 | */ | ||
43 | protected EList<Node> literals; | ||
44 | |||
45 | /** | ||
46 | * <!-- begin-user-doc --> | ||
47 | * <!-- end-user-doc --> | ||
48 | * @generated | ||
49 | */ | ||
50 | protected EnumDeclarationImpl() { | ||
51 | super(); | ||
52 | } | ||
53 | |||
54 | /** | ||
55 | * <!-- begin-user-doc --> | ||
56 | * <!-- end-user-doc --> | ||
57 | * @generated | ||
58 | */ | ||
59 | @Override | ||
60 | protected EClass eStaticClass() { | ||
61 | return ProblemPackage.Literals.ENUM_DECLARATION; | ||
62 | } | ||
63 | |||
64 | /** | ||
65 | * <!-- begin-user-doc --> | ||
66 | * <!-- end-user-doc --> | ||
67 | * @generated | ||
68 | */ | ||
69 | public EList<Node> getLiterals() { | ||
70 | if (literals == null) { | ||
71 | literals = new EObjectContainmentEList<Node>(Node.class, this, ProblemPackage.ENUM_DECLARATION__LITERALS); | ||
72 | } | ||
73 | return literals; | ||
74 | } | ||
75 | |||
76 | /** | ||
77 | * <!-- begin-user-doc --> | ||
78 | * <!-- end-user-doc --> | ||
79 | * @generated | ||
80 | */ | ||
81 | @Override | ||
82 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
83 | switch (featureID) { | ||
84 | case ProblemPackage.ENUM_DECLARATION__LITERALS: | ||
85 | return ((InternalEList<?>) getLiterals()).basicRemove(otherEnd, msgs); | ||
86 | } | ||
87 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
88 | } | ||
89 | |||
90 | /** | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @generated | ||
94 | */ | ||
95 | @Override | ||
96 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
97 | switch (featureID) { | ||
98 | case ProblemPackage.ENUM_DECLARATION__LITERALS: | ||
99 | return getLiterals(); | ||
100 | } | ||
101 | return super.eGet(featureID, resolve, coreType); | ||
102 | } | ||
103 | |||
104 | /** | ||
105 | * <!-- begin-user-doc --> | ||
106 | * <!-- end-user-doc --> | ||
107 | * @generated | ||
108 | */ | ||
109 | @SuppressWarnings("unchecked") | ||
110 | @Override | ||
111 | public void eSet(int featureID, Object newValue) { | ||
112 | switch (featureID) { | ||
113 | case ProblemPackage.ENUM_DECLARATION__LITERALS: | ||
114 | getLiterals().clear(); | ||
115 | getLiterals().addAll((Collection<? extends Node>) newValue); | ||
116 | return; | ||
117 | } | ||
118 | super.eSet(featureID, newValue); | ||
119 | } | ||
120 | |||
121 | /** | ||
122 | * <!-- begin-user-doc --> | ||
123 | * <!-- end-user-doc --> | ||
124 | * @generated | ||
125 | */ | ||
126 | @Override | ||
127 | public void eUnset(int featureID) { | ||
128 | switch (featureID) { | ||
129 | case ProblemPackage.ENUM_DECLARATION__LITERALS: | ||
130 | getLiterals().clear(); | ||
131 | return; | ||
132 | } | ||
133 | super.eUnset(featureID); | ||
134 | } | ||
135 | |||
136 | /** | ||
137 | * <!-- begin-user-doc --> | ||
138 | * <!-- end-user-doc --> | ||
139 | * @generated | ||
140 | */ | ||
141 | @Override | ||
142 | public boolean eIsSet(int featureID) { | ||
143 | switch (featureID) { | ||
144 | case ProblemPackage.ENUM_DECLARATION__LITERALS: | ||
145 | return literals != null && !literals.isEmpty(); | ||
146 | } | ||
147 | return super.eIsSet(featureID); | ||
148 | } | ||
149 | |||
150 | } //EnumDeclarationImpl | ||
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/NodeImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/NodeImpl.java index 23b85a9c..0c08bb1b 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/NodeImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/NodeImpl.java | |||
@@ -14,7 +14,7 @@ import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | |||
14 | * | 14 | * |
15 | * @generated | 15 | * @generated |
16 | */ | 16 | */ |
17 | public class NodeImpl extends NamedElementImpl implements Node { | 17 | public class NodeImpl extends VariableOrNodeImpl implements Node { |
18 | /** | 18 | /** |
19 | * <!-- begin-user-doc --> | 19 | * <!-- begin-user-doc --> |
20 | * <!-- end-user-doc --> | 20 | * <!-- end-user-doc --> |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ParameterImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ParameterImpl.java index cfbf25b0..06eea3f3 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ParameterImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ParameterImpl.java | |||
@@ -8,10 +8,9 @@ import org.eclipse.emf.ecore.EClass; | |||
8 | import org.eclipse.emf.ecore.InternalEObject; | 8 | import org.eclipse.emf.ecore.InternalEObject; |
9 | 9 | ||
10 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | 10 | import org.eclipse.emf.ecore.impl.ENotificationImpl; |
11 | |||
12 | import org.eclipse.viatra.solver.language.model.problem.ClassDeclaration; | ||
13 | import org.eclipse.viatra.solver.language.model.problem.Parameter; | 11 | import org.eclipse.viatra.solver.language.model.problem.Parameter; |
14 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | 12 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; |
13 | import org.eclipse.viatra.solver.language.model.problem.Relation; | ||
15 | 14 | ||
16 | /** | 15 | /** |
17 | * <!-- begin-user-doc --> | 16 | * <!-- begin-user-doc --> |
@@ -35,7 +34,7 @@ public class ParameterImpl extends VariableImpl implements Parameter { | |||
35 | * @generated | 34 | * @generated |
36 | * @ordered | 35 | * @ordered |
37 | */ | 36 | */ |
38 | protected ClassDeclaration parameterType; | 37 | protected Relation parameterType; |
39 | 38 | ||
40 | /** | 39 | /** |
41 | * <!-- begin-user-doc --> | 40 | * <!-- begin-user-doc --> |
@@ -61,10 +60,10 @@ public class ParameterImpl extends VariableImpl implements Parameter { | |||
61 | * <!-- end-user-doc --> | 60 | * <!-- end-user-doc --> |
62 | * @generated | 61 | * @generated |
63 | */ | 62 | */ |
64 | public ClassDeclaration getParameterType() { | 63 | public Relation getParameterType() { |
65 | if (parameterType != null && parameterType.eIsProxy()) { | 64 | if (parameterType != null && parameterType.eIsProxy()) { |
66 | InternalEObject oldParameterType = (InternalEObject) parameterType; | 65 | InternalEObject oldParameterType = (InternalEObject) parameterType; |
67 | parameterType = (ClassDeclaration) eResolveProxy(oldParameterType); | 66 | parameterType = (Relation) eResolveProxy(oldParameterType); |
68 | if (parameterType != oldParameterType) { | 67 | if (parameterType != oldParameterType) { |
69 | if (eNotificationRequired()) | 68 | if (eNotificationRequired()) |
70 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, ProblemPackage.PARAMETER__PARAMETER_TYPE, | 69 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, ProblemPackage.PARAMETER__PARAMETER_TYPE, |
@@ -79,7 +78,7 @@ public class ParameterImpl extends VariableImpl implements Parameter { | |||
79 | * <!-- end-user-doc --> | 78 | * <!-- end-user-doc --> |
80 | * @generated | 79 | * @generated |
81 | */ | 80 | */ |
82 | public ClassDeclaration basicGetParameterType() { | 81 | public Relation basicGetParameterType() { |
83 | return parameterType; | 82 | return parameterType; |
84 | } | 83 | } |
85 | 84 | ||
@@ -88,8 +87,8 @@ public class ParameterImpl extends VariableImpl implements Parameter { | |||
88 | * <!-- end-user-doc --> | 87 | * <!-- end-user-doc --> |
89 | * @generated | 88 | * @generated |
90 | */ | 89 | */ |
91 | public void setParameterType(ClassDeclaration newParameterType) { | 90 | public void setParameterType(Relation newParameterType) { |
92 | ClassDeclaration oldParameterType = parameterType; | 91 | Relation oldParameterType = parameterType; |
93 | parameterType = newParameterType; | 92 | parameterType = newParameterType; |
94 | if (eNotificationRequired()) | 93 | if (eNotificationRequired()) |
95 | eNotify(new ENotificationImpl(this, Notification.SET, ProblemPackage.PARAMETER__PARAMETER_TYPE, | 94 | eNotify(new ENotificationImpl(this, Notification.SET, ProblemPackage.PARAMETER__PARAMETER_TYPE, |
@@ -121,7 +120,7 @@ public class ParameterImpl extends VariableImpl implements Parameter { | |||
121 | public void eSet(int featureID, Object newValue) { | 120 | public void eSet(int featureID, Object newValue) { |
122 | switch (featureID) { | 121 | switch (featureID) { |
123 | case ProblemPackage.PARAMETER__PARAMETER_TYPE: | 122 | case ProblemPackage.PARAMETER__PARAMETER_TYPE: |
124 | setParameterType((ClassDeclaration) newValue); | 123 | setParameterType((Relation) newValue); |
125 | return; | 124 | return; |
126 | } | 125 | } |
127 | super.eSet(featureID, newValue); | 126 | super.eSet(featureID, newValue); |
@@ -136,7 +135,7 @@ public class ParameterImpl extends VariableImpl implements Parameter { | |||
136 | public void eUnset(int featureID) { | 135 | public void eUnset(int featureID) { |
137 | switch (featureID) { | 136 | switch (featureID) { |
138 | case ProblemPackage.PARAMETER__PARAMETER_TYPE: | 137 | case ProblemPackage.PARAMETER__PARAMETER_TYPE: |
139 | setParameterType((ClassDeclaration) null); | 138 | setParameterType((Relation) null); |
140 | return; | 139 | return; |
141 | } | 140 | } |
142 | super.eUnset(featureID); | 141 | super.eUnset(featureID); |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemFactoryImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemFactoryImpl.java index 3bb50cfe..2f4144b9 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemFactoryImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemFactoryImpl.java | |||
@@ -91,6 +91,8 @@ public class ProblemFactoryImpl extends EFactoryImpl implements ProblemFactory { | |||
91 | return createUnboundedMultiplicity(); | 91 | return createUnboundedMultiplicity(); |
92 | case ProblemPackage.ARGUMENT: | 92 | case ProblemPackage.ARGUMENT: |
93 | return createArgument(); | 93 | return createArgument(); |
94 | case ProblemPackage.ENUM_DECLARATION: | ||
95 | return createEnumDeclaration(); | ||
94 | default: | 96 | default: |
95 | throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); | 97 | throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier"); |
96 | } | 98 | } |
@@ -301,6 +303,16 @@ public class ProblemFactoryImpl extends EFactoryImpl implements ProblemFactory { | |||
301 | * <!-- end-user-doc --> | 303 | * <!-- end-user-doc --> |
302 | * @generated | 304 | * @generated |
303 | */ | 305 | */ |
306 | public EnumDeclaration createEnumDeclaration() { | ||
307 | EnumDeclarationImpl enumDeclaration = new EnumDeclarationImpl(); | ||
308 | return enumDeclaration; | ||
309 | } | ||
310 | |||
311 | /** | ||
312 | * <!-- begin-user-doc --> | ||
313 | * <!-- end-user-doc --> | ||
314 | * @generated | ||
315 | */ | ||
304 | public LogicValue createLogicValueFromString(EDataType eDataType, String initialValue) { | 316 | public LogicValue createLogicValueFromString(EDataType eDataType, String initialValue) { |
305 | LogicValue result = LogicValue.get(initialValue); | 317 | LogicValue result = LogicValue.get(initialValue); |
306 | if (result == null) | 318 | if (result == null) |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemPackageImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemPackageImpl.java index f412addc..d10ff2f0 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemPackageImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ProblemPackageImpl.java | |||
@@ -15,6 +15,7 @@ import org.eclipse.viatra.solver.language.model.problem.Assertion; | |||
15 | import org.eclipse.viatra.solver.language.model.problem.Atom; | 15 | import org.eclipse.viatra.solver.language.model.problem.Atom; |
16 | import org.eclipse.viatra.solver.language.model.problem.ClassDeclaration; | 16 | import org.eclipse.viatra.solver.language.model.problem.ClassDeclaration; |
17 | import org.eclipse.viatra.solver.language.model.problem.Conjunction; | 17 | import org.eclipse.viatra.solver.language.model.problem.Conjunction; |
18 | import org.eclipse.viatra.solver.language.model.problem.EnumDeclaration; | ||
18 | import org.eclipse.viatra.solver.language.model.problem.ExactMultiplicity; | 19 | import org.eclipse.viatra.solver.language.model.problem.ExactMultiplicity; |
19 | import org.eclipse.viatra.solver.language.model.problem.ExistentialQuantifier; | 20 | import org.eclipse.viatra.solver.language.model.problem.ExistentialQuantifier; |
20 | import org.eclipse.viatra.solver.language.model.problem.ImplicitVariable; | 21 | import org.eclipse.viatra.solver.language.model.problem.ImplicitVariable; |
@@ -37,6 +38,7 @@ import org.eclipse.viatra.solver.language.model.problem.Statement; | |||
37 | import org.eclipse.viatra.solver.language.model.problem.TypeScope; | 38 | import org.eclipse.viatra.solver.language.model.problem.TypeScope; |
38 | import org.eclipse.viatra.solver.language.model.problem.UnboundedMultiplicity; | 39 | import org.eclipse.viatra.solver.language.model.problem.UnboundedMultiplicity; |
39 | import org.eclipse.viatra.solver.language.model.problem.Variable; | 40 | import org.eclipse.viatra.solver.language.model.problem.Variable; |
41 | import org.eclipse.viatra.solver.language.model.problem.VariableOrNode; | ||
40 | 42 | ||
41 | /** | 43 | /** |
42 | * <!-- begin-user-doc --> | 44 | * <!-- begin-user-doc --> |
@@ -218,6 +220,20 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
218 | * <!-- end-user-doc --> | 220 | * <!-- end-user-doc --> |
219 | * @generated | 221 | * @generated |
220 | */ | 222 | */ |
223 | private EClass enumDeclarationEClass = null; | ||
224 | |||
225 | /** | ||
226 | * <!-- begin-user-doc --> | ||
227 | * <!-- end-user-doc --> | ||
228 | * @generated | ||
229 | */ | ||
230 | private EClass variableOrNodeEClass = null; | ||
231 | |||
232 | /** | ||
233 | * <!-- begin-user-doc --> | ||
234 | * <!-- end-user-doc --> | ||
235 | * @generated | ||
236 | */ | ||
221 | private EEnum logicValueEEnum = null; | 237 | private EEnum logicValueEEnum = null; |
222 | 238 | ||
223 | /** | 239 | /** |
@@ -784,7 +800,7 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
784 | * <!-- end-user-doc --> | 800 | * <!-- end-user-doc --> |
785 | * @generated | 801 | * @generated |
786 | */ | 802 | */ |
787 | public EReference getArgument_Variable() { | 803 | public EReference getArgument_VariableOrNode() { |
788 | return (EReference) argumentEClass.getEStructuralFeatures().get(0); | 804 | return (EReference) argumentEClass.getEStructuralFeatures().get(0); |
789 | } | 805 | } |
790 | 806 | ||
@@ -802,6 +818,33 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
802 | * <!-- end-user-doc --> | 818 | * <!-- end-user-doc --> |
803 | * @generated | 819 | * @generated |
804 | */ | 820 | */ |
821 | public EClass getEnumDeclaration() { | ||
822 | return enumDeclarationEClass; | ||
823 | } | ||
824 | |||
825 | /** | ||
826 | * <!-- begin-user-doc --> | ||
827 | * <!-- end-user-doc --> | ||
828 | * @generated | ||
829 | */ | ||
830 | public EReference getEnumDeclaration_Literals() { | ||
831 | return (EReference) enumDeclarationEClass.getEStructuralFeatures().get(0); | ||
832 | } | ||
833 | |||
834 | /** | ||
835 | * <!-- begin-user-doc --> | ||
836 | * <!-- end-user-doc --> | ||
837 | * @generated | ||
838 | */ | ||
839 | public EClass getVariableOrNode() { | ||
840 | return variableOrNodeEClass; | ||
841 | } | ||
842 | |||
843 | /** | ||
844 | * <!-- begin-user-doc --> | ||
845 | * <!-- end-user-doc --> | ||
846 | * @generated | ||
847 | */ | ||
805 | public EEnum getLogicValue() { | 848 | public EEnum getLogicValue() { |
806 | return logicValueEEnum; | 849 | return logicValueEEnum; |
807 | } | 850 | } |
@@ -913,9 +956,14 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
913 | unboundedMultiplicityEClass = createEClass(UNBOUNDED_MULTIPLICITY); | 956 | unboundedMultiplicityEClass = createEClass(UNBOUNDED_MULTIPLICITY); |
914 | 957 | ||
915 | argumentEClass = createEClass(ARGUMENT); | 958 | argumentEClass = createEClass(ARGUMENT); |
916 | createEReference(argumentEClass, ARGUMENT__VARIABLE); | 959 | createEReference(argumentEClass, ARGUMENT__VARIABLE_OR_NODE); |
917 | createEReference(argumentEClass, ARGUMENT__SINGLETON_VARIABLE); | 960 | createEReference(argumentEClass, ARGUMENT__SINGLETON_VARIABLE); |
918 | 961 | ||
962 | enumDeclarationEClass = createEClass(ENUM_DECLARATION); | ||
963 | createEReference(enumDeclarationEClass, ENUM_DECLARATION__LITERALS); | ||
964 | |||
965 | variableOrNodeEClass = createEClass(VARIABLE_OR_NODE); | ||
966 | |||
919 | // Create enums | 967 | // Create enums |
920 | logicValueEEnum = createEEnum(LOGIC_VALUE); | 968 | logicValueEEnum = createEEnum(LOGIC_VALUE); |
921 | } | 969 | } |
@@ -957,18 +1005,21 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
957 | predicateDefinitionEClass.getESuperTypes().add(this.getRelation()); | 1005 | predicateDefinitionEClass.getESuperTypes().add(this.getRelation()); |
958 | predicateDefinitionEClass.getESuperTypes().add(this.getStatement()); | 1006 | predicateDefinitionEClass.getESuperTypes().add(this.getStatement()); |
959 | parameterEClass.getESuperTypes().add(this.getVariable()); | 1007 | parameterEClass.getESuperTypes().add(this.getVariable()); |
960 | variableEClass.getESuperTypes().add(this.getNamedElement()); | 1008 | variableEClass.getESuperTypes().add(this.getVariableOrNode()); |
961 | conjunctionEClass.getESuperTypes().add(this.getExistentialQuantifier()); | 1009 | conjunctionEClass.getESuperTypes().add(this.getExistentialQuantifier()); |
962 | atomEClass.getESuperTypes().add(this.getLiteral()); | 1010 | atomEClass.getESuperTypes().add(this.getLiteral()); |
963 | implicitVariableEClass.getESuperTypes().add(this.getVariable()); | 1011 | implicitVariableEClass.getESuperTypes().add(this.getVariable()); |
964 | negativeLiteralEClass.getESuperTypes().add(this.getExistentialQuantifier()); | 1012 | negativeLiteralEClass.getESuperTypes().add(this.getExistentialQuantifier()); |
965 | negativeLiteralEClass.getESuperTypes().add(this.getLiteral()); | 1013 | negativeLiteralEClass.getESuperTypes().add(this.getLiteral()); |
966 | assertionEClass.getESuperTypes().add(this.getStatement()); | 1014 | assertionEClass.getESuperTypes().add(this.getStatement()); |
967 | nodeEClass.getESuperTypes().add(this.getNamedElement()); | 1015 | nodeEClass.getESuperTypes().add(this.getVariableOrNode()); |
968 | scopeDeclarationEClass.getESuperTypes().add(this.getStatement()); | 1016 | scopeDeclarationEClass.getESuperTypes().add(this.getStatement()); |
969 | rangeMultiplicityEClass.getESuperTypes().add(this.getMultiplicity()); | 1017 | rangeMultiplicityEClass.getESuperTypes().add(this.getMultiplicity()); |
970 | exactMultiplicityEClass.getESuperTypes().add(this.getMultiplicity()); | 1018 | exactMultiplicityEClass.getESuperTypes().add(this.getMultiplicity()); |
971 | unboundedMultiplicityEClass.getESuperTypes().add(this.getMultiplicity()); | 1019 | unboundedMultiplicityEClass.getESuperTypes().add(this.getMultiplicity()); |
1020 | enumDeclarationEClass.getESuperTypes().add(this.getRelation()); | ||
1021 | enumDeclarationEClass.getESuperTypes().add(this.getStatement()); | ||
1022 | variableOrNodeEClass.getESuperTypes().add(this.getNamedElement()); | ||
972 | 1023 | ||
973 | // Initialize classes, features, and operations; add parameters | 1024 | // Initialize classes, features, and operations; add parameters |
974 | initEClass(problemEClass, Problem.class, "Problem", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | 1025 | initEClass(problemEClass, Problem.class, "Problem", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); |
@@ -986,7 +1037,7 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
986 | initEAttribute(getClassDeclaration_Abstract(), ecorePackage.getEBoolean(), "abstract", null, 0, 1, | 1037 | initEAttribute(getClassDeclaration_Abstract(), ecorePackage.getEBoolean(), "abstract", null, 0, 1, |
987 | ClassDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, | 1038 | ClassDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, |
988 | !IS_DERIVED, IS_ORDERED); | 1039 | !IS_DERIVED, IS_ORDERED); |
989 | initEReference(getClassDeclaration_SuperTypes(), this.getClassDeclaration(), null, "superTypes", null, 0, -1, | 1040 | initEReference(getClassDeclaration_SuperTypes(), this.getRelation(), null, "superTypes", null, 0, -1, |
990 | ClassDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, | 1041 | ClassDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, |
991 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | 1042 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); |
992 | initEReference(getClassDeclaration_ReferenceDeclarations(), this.getReferenceDeclaration(), null, | 1043 | initEReference(getClassDeclaration_ReferenceDeclarations(), this.getReferenceDeclaration(), null, |
@@ -998,8 +1049,8 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
998 | 1049 | ||
999 | initEClass(referenceDeclarationEClass, ReferenceDeclaration.class, "ReferenceDeclaration", !IS_ABSTRACT, | 1050 | initEClass(referenceDeclarationEClass, ReferenceDeclaration.class, "ReferenceDeclaration", !IS_ABSTRACT, |
1000 | !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); | 1051 | !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); |
1001 | initEReference(getReferenceDeclaration_ReferenceType(), this.getClassDeclaration(), null, "referenceType", null, | 1052 | initEReference(getReferenceDeclaration_ReferenceType(), this.getRelation(), null, "referenceType", null, 0, 1, |
1002 | 0, 1, ReferenceDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, | 1053 | ReferenceDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, |
1003 | IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | 1054 | IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); |
1004 | initEReference(getReferenceDeclaration_Opposite(), this.getReferenceDeclaration(), null, "opposite", null, 0, 1, | 1055 | initEReference(getReferenceDeclaration_Opposite(), this.getReferenceDeclaration(), null, "opposite", null, 0, 1, |
1005 | ReferenceDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, | 1056 | ReferenceDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, |
@@ -1030,7 +1081,7 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
1030 | 1081 | ||
1031 | initEClass(parameterEClass, Parameter.class, "Parameter", !IS_ABSTRACT, !IS_INTERFACE, | 1082 | initEClass(parameterEClass, Parameter.class, "Parameter", !IS_ABSTRACT, !IS_INTERFACE, |
1032 | IS_GENERATED_INSTANCE_CLASS); | 1083 | IS_GENERATED_INSTANCE_CLASS); |
1033 | initEReference(getParameter_ParameterType(), this.getClassDeclaration(), null, "parameterType", null, 0, 1, | 1084 | initEReference(getParameter_ParameterType(), this.getRelation(), null, "parameterType", null, 0, 1, |
1034 | Parameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, | 1085 | Parameter.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, |
1035 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | 1086 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); |
1036 | 1087 | ||
@@ -1126,13 +1177,22 @@ public class ProblemPackageImpl extends EPackageImpl implements ProblemPackage { | |||
1126 | 1177 | ||
1127 | initEClass(argumentEClass, Argument.class, "Argument", !IS_ABSTRACT, !IS_INTERFACE, | 1178 | initEClass(argumentEClass, Argument.class, "Argument", !IS_ABSTRACT, !IS_INTERFACE, |
1128 | IS_GENERATED_INSTANCE_CLASS); | 1179 | IS_GENERATED_INSTANCE_CLASS); |
1129 | initEReference(getArgument_Variable(), this.getVariable(), null, "variable", null, 0, 1, Argument.class, | 1180 | initEReference(getArgument_VariableOrNode(), this.getVariableOrNode(), null, "variableOrNode", null, 0, 1, |
1130 | !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, | 1181 | Argument.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, |
1131 | IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | 1182 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); |
1132 | initEReference(getArgument_SingletonVariable(), this.getImplicitVariable(), null, "singletonVariable", null, 0, | 1183 | initEReference(getArgument_SingletonVariable(), this.getImplicitVariable(), null, "singletonVariable", null, 0, |
1133 | 1, Argument.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, | 1184 | 1, Argument.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, |
1134 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | 1185 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); |
1135 | 1186 | ||
1187 | initEClass(enumDeclarationEClass, EnumDeclaration.class, "EnumDeclaration", !IS_ABSTRACT, !IS_INTERFACE, | ||
1188 | IS_GENERATED_INSTANCE_CLASS); | ||
1189 | initEReference(getEnumDeclaration_Literals(), this.getNode(), null, "literals", null, 0, -1, | ||
1190 | EnumDeclaration.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, | ||
1191 | !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); | ||
1192 | |||
1193 | initEClass(variableOrNodeEClass, VariableOrNode.class, "VariableOrNode", IS_ABSTRACT, !IS_INTERFACE, | ||
1194 | IS_GENERATED_INSTANCE_CLASS); | ||
1195 | |||
1136 | // Initialize enums and add enum literals | 1196 | // Initialize enums and add enum literals |
1137 | initEEnum(logicValueEEnum, LogicValue.class, "LogicValue"); | 1197 | initEEnum(logicValueEEnum, LogicValue.class, "LogicValue"); |
1138 | addEEnumLiteral(logicValueEEnum, LogicValue.TRUE); | 1198 | addEEnumLiteral(logicValueEEnum, LogicValue.TRUE); |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ReferenceDeclarationImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ReferenceDeclarationImpl.java index 424db23d..8df2715f 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ReferenceDeclarationImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/ReferenceDeclarationImpl.java | |||
@@ -9,11 +9,10 @@ import org.eclipse.emf.ecore.EClass; | |||
9 | import org.eclipse.emf.ecore.InternalEObject; | 9 | import org.eclipse.emf.ecore.InternalEObject; |
10 | 10 | ||
11 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | 11 | import org.eclipse.emf.ecore.impl.ENotificationImpl; |
12 | |||
13 | import org.eclipse.viatra.solver.language.model.problem.ClassDeclaration; | ||
14 | import org.eclipse.viatra.solver.language.model.problem.Multiplicity; | 12 | import org.eclipse.viatra.solver.language.model.problem.Multiplicity; |
15 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | 13 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; |
16 | import org.eclipse.viatra.solver.language.model.problem.ReferenceDeclaration; | 14 | import org.eclipse.viatra.solver.language.model.problem.ReferenceDeclaration; |
15 | import org.eclipse.viatra.solver.language.model.problem.Relation; | ||
17 | 16 | ||
18 | /** | 17 | /** |
19 | * <!-- begin-user-doc --> | 18 | * <!-- begin-user-doc --> |
@@ -40,7 +39,7 @@ public class ReferenceDeclarationImpl extends RelationImpl implements ReferenceD | |||
40 | * @generated | 39 | * @generated |
41 | * @ordered | 40 | * @ordered |
42 | */ | 41 | */ |
43 | protected ClassDeclaration referenceType; | 42 | protected Relation referenceType; |
44 | 43 | ||
45 | /** | 44 | /** |
46 | * The cached value of the '{@link #getOpposite() <em>Opposite</em>}' reference. | 45 | * The cached value of the '{@link #getOpposite() <em>Opposite</em>}' reference. |
@@ -106,10 +105,10 @@ public class ReferenceDeclarationImpl extends RelationImpl implements ReferenceD | |||
106 | * <!-- end-user-doc --> | 105 | * <!-- end-user-doc --> |
107 | * @generated | 106 | * @generated |
108 | */ | 107 | */ |
109 | public ClassDeclaration getReferenceType() { | 108 | public Relation getReferenceType() { |
110 | if (referenceType != null && referenceType.eIsProxy()) { | 109 | if (referenceType != null && referenceType.eIsProxy()) { |
111 | InternalEObject oldReferenceType = (InternalEObject) referenceType; | 110 | InternalEObject oldReferenceType = (InternalEObject) referenceType; |
112 | referenceType = (ClassDeclaration) eResolveProxy(oldReferenceType); | 111 | referenceType = (Relation) eResolveProxy(oldReferenceType); |
113 | if (referenceType != oldReferenceType) { | 112 | if (referenceType != oldReferenceType) { |
114 | if (eNotificationRequired()) | 113 | if (eNotificationRequired()) |
115 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, | 114 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, |
@@ -124,7 +123,7 @@ public class ReferenceDeclarationImpl extends RelationImpl implements ReferenceD | |||
124 | * <!-- end-user-doc --> | 123 | * <!-- end-user-doc --> |
125 | * @generated | 124 | * @generated |
126 | */ | 125 | */ |
127 | public ClassDeclaration basicGetReferenceType() { | 126 | public Relation basicGetReferenceType() { |
128 | return referenceType; | 127 | return referenceType; |
129 | } | 128 | } |
130 | 129 | ||
@@ -133,8 +132,8 @@ public class ReferenceDeclarationImpl extends RelationImpl implements ReferenceD | |||
133 | * <!-- end-user-doc --> | 132 | * <!-- end-user-doc --> |
134 | * @generated | 133 | * @generated |
135 | */ | 134 | */ |
136 | public void setReferenceType(ClassDeclaration newReferenceType) { | 135 | public void setReferenceType(Relation newReferenceType) { |
137 | ClassDeclaration oldReferenceType = referenceType; | 136 | Relation oldReferenceType = referenceType; |
138 | referenceType = newReferenceType; | 137 | referenceType = newReferenceType; |
139 | if (eNotificationRequired()) | 138 | if (eNotificationRequired()) |
140 | eNotify(new ENotificationImpl(this, Notification.SET, ProblemPackage.REFERENCE_DECLARATION__REFERENCE_TYPE, | 139 | eNotify(new ENotificationImpl(this, Notification.SET, ProblemPackage.REFERENCE_DECLARATION__REFERENCE_TYPE, |
@@ -300,7 +299,7 @@ public class ReferenceDeclarationImpl extends RelationImpl implements ReferenceD | |||
300 | public void eSet(int featureID, Object newValue) { | 299 | public void eSet(int featureID, Object newValue) { |
301 | switch (featureID) { | 300 | switch (featureID) { |
302 | case ProblemPackage.REFERENCE_DECLARATION__REFERENCE_TYPE: | 301 | case ProblemPackage.REFERENCE_DECLARATION__REFERENCE_TYPE: |
303 | setReferenceType((ClassDeclaration) newValue); | 302 | setReferenceType((Relation) newValue); |
304 | return; | 303 | return; |
305 | case ProblemPackage.REFERENCE_DECLARATION__OPPOSITE: | 304 | case ProblemPackage.REFERENCE_DECLARATION__OPPOSITE: |
306 | setOpposite((ReferenceDeclaration) newValue); | 305 | setOpposite((ReferenceDeclaration) newValue); |
@@ -324,7 +323,7 @@ public class ReferenceDeclarationImpl extends RelationImpl implements ReferenceD | |||
324 | public void eUnset(int featureID) { | 323 | public void eUnset(int featureID) { |
325 | switch (featureID) { | 324 | switch (featureID) { |
326 | case ProblemPackage.REFERENCE_DECLARATION__REFERENCE_TYPE: | 325 | case ProblemPackage.REFERENCE_DECLARATION__REFERENCE_TYPE: |
327 | setReferenceType((ClassDeclaration) null); | 326 | setReferenceType((Relation) null); |
328 | return; | 327 | return; |
329 | case ProblemPackage.REFERENCE_DECLARATION__OPPOSITE: | 328 | case ProblemPackage.REFERENCE_DECLARATION__OPPOSITE: |
330 | setOpposite((ReferenceDeclaration) null); | 329 | setOpposite((ReferenceDeclaration) null); |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableImpl.java index 0a8cde48..645ac39c 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableImpl.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableImpl.java | |||
@@ -14,7 +14,7 @@ import org.eclipse.viatra.solver.language.model.problem.Variable; | |||
14 | * | 14 | * |
15 | * @generated | 15 | * @generated |
16 | */ | 16 | */ |
17 | public abstract class VariableImpl extends NamedElementImpl implements Variable { | 17 | public abstract class VariableImpl extends VariableOrNodeImpl implements Variable { |
18 | /** | 18 | /** |
19 | * <!-- begin-user-doc --> | 19 | * <!-- begin-user-doc --> |
20 | * <!-- end-user-doc --> | 20 | * <!-- end-user-doc --> |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableOrNodeImpl.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableOrNodeImpl.java new file mode 100644 index 00000000..4964a019 --- /dev/null +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/impl/VariableOrNodeImpl.java | |||
@@ -0,0 +1,37 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package org.eclipse.viatra.solver.language.model.problem.impl; | ||
4 | |||
5 | import org.eclipse.emf.ecore.EClass; | ||
6 | |||
7 | import org.eclipse.viatra.solver.language.model.problem.ProblemPackage; | ||
8 | import org.eclipse.viatra.solver.language.model.problem.VariableOrNode; | ||
9 | |||
10 | /** | ||
11 | * <!-- begin-user-doc --> | ||
12 | * An implementation of the model object '<em><b>Variable Or Node</b></em>'. | ||
13 | * <!-- end-user-doc --> | ||
14 | * | ||
15 | * @generated | ||
16 | */ | ||
17 | public abstract class VariableOrNodeImpl extends NamedElementImpl implements VariableOrNode { | ||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * <!-- end-user-doc --> | ||
21 | * @generated | ||
22 | */ | ||
23 | protected VariableOrNodeImpl() { | ||
24 | super(); | ||
25 | } | ||
26 | |||
27 | /** | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | @Override | ||
33 | protected EClass eStaticClass() { | ||
34 | return ProblemPackage.Literals.VARIABLE_OR_NODE; | ||
35 | } | ||
36 | |||
37 | } //VariableOrNodeImpl | ||
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemAdapterFactory.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemAdapterFactory.java index c41a4034..3fc3ca75 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemAdapterFactory.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemAdapterFactory.java | |||
@@ -187,6 +187,16 @@ public class ProblemAdapterFactory extends AdapterFactoryImpl { | |||
187 | } | 187 | } |
188 | 188 | ||
189 | @Override | 189 | @Override |
190 | public Adapter caseEnumDeclaration(EnumDeclaration object) { | ||
191 | return createEnumDeclarationAdapter(); | ||
192 | } | ||
193 | |||
194 | @Override | ||
195 | public Adapter caseVariableOrNode(VariableOrNode object) { | ||
196 | return createVariableOrNodeAdapter(); | ||
197 | } | ||
198 | |||
199 | @Override | ||
190 | public Adapter defaultCase(EObject object) { | 200 | public Adapter defaultCase(EObject object) { |
191 | return createEObjectAdapter(); | 201 | return createEObjectAdapter(); |
192 | } | 202 | } |
@@ -542,6 +552,34 @@ public class ProblemAdapterFactory extends AdapterFactoryImpl { | |||
542 | } | 552 | } |
543 | 553 | ||
544 | /** | 554 | /** |
555 | * Creates a new adapter for an object of class '{@link org.eclipse.viatra.solver.language.model.problem.EnumDeclaration <em>Enum Declaration</em>}'. | ||
556 | * <!-- begin-user-doc --> | ||
557 | * This default implementation returns null so that we can easily ignore cases; | ||
558 | * it's useful to ignore a case when inheritance will catch all the cases anyway. | ||
559 | * <!-- end-user-doc --> | ||
560 | * @return the new adapter. | ||
561 | * @see org.eclipse.viatra.solver.language.model.problem.EnumDeclaration | ||
562 | * @generated | ||
563 | */ | ||
564 | public Adapter createEnumDeclarationAdapter() { | ||
565 | return null; | ||
566 | } | ||
567 | |||
568 | /** | ||
569 | * Creates a new adapter for an object of class '{@link org.eclipse.viatra.solver.language.model.problem.VariableOrNode <em>Variable Or Node</em>}'. | ||
570 | * <!-- begin-user-doc --> | ||
571 | * This default implementation returns null so that we can easily ignore cases; | ||
572 | * it's useful to ignore a case when inheritance will catch all the cases anyway. | ||
573 | * <!-- end-user-doc --> | ||
574 | * @return the new adapter. | ||
575 | * @see org.eclipse.viatra.solver.language.model.problem.VariableOrNode | ||
576 | * @generated | ||
577 | */ | ||
578 | public Adapter createVariableOrNodeAdapter() { | ||
579 | return null; | ||
580 | } | ||
581 | |||
582 | /** | ||
545 | * Creates a new adapter for the default case. | 583 | * Creates a new adapter for the default case. |
546 | * <!-- begin-user-doc --> | 584 | * <!-- begin-user-doc --> |
547 | * This default implementation returns null. | 585 | * This default implementation returns null. |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemSwitch.java b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemSwitch.java index 361b663c..b74718b5 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemSwitch.java +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/emf-gen/org/eclipse/viatra/solver/language/model/problem/util/ProblemSwitch.java | |||
@@ -134,6 +134,8 @@ public class ProblemSwitch<T> extends Switch<T> { | |||
134 | if (result == null) | 134 | if (result == null) |
135 | result = caseVariable(parameter); | 135 | result = caseVariable(parameter); |
136 | if (result == null) | 136 | if (result == null) |
137 | result = caseVariableOrNode(parameter); | ||
138 | if (result == null) | ||
137 | result = caseNamedElement(parameter); | 139 | result = caseNamedElement(parameter); |
138 | if (result == null) | 140 | if (result == null) |
139 | result = defaultCase(theEObject); | 141 | result = defaultCase(theEObject); |
@@ -143,6 +145,8 @@ public class ProblemSwitch<T> extends Switch<T> { | |||
143 | Variable variable = (Variable) theEObject; | 145 | Variable variable = (Variable) theEObject; |
144 | T result = caseVariable(variable); | 146 | T result = caseVariable(variable); |
145 | if (result == null) | 147 | if (result == null) |
148 | result = caseVariableOrNode(variable); | ||
149 | if (result == null) | ||
146 | result = caseNamedElement(variable); | 150 | result = caseNamedElement(variable); |
147 | if (result == null) | 151 | if (result == null) |
148 | result = defaultCase(theEObject); | 152 | result = defaultCase(theEObject); |
@@ -179,6 +183,8 @@ public class ProblemSwitch<T> extends Switch<T> { | |||
179 | if (result == null) | 183 | if (result == null) |
180 | result = caseVariable(implicitVariable); | 184 | result = caseVariable(implicitVariable); |
181 | if (result == null) | 185 | if (result == null) |
186 | result = caseVariableOrNode(implicitVariable); | ||
187 | if (result == null) | ||
182 | result = caseNamedElement(implicitVariable); | 188 | result = caseNamedElement(implicitVariable); |
183 | if (result == null) | 189 | if (result == null) |
184 | result = defaultCase(theEObject); | 190 | result = defaultCase(theEObject); |
@@ -215,6 +221,8 @@ public class ProblemSwitch<T> extends Switch<T> { | |||
215 | Node node = (Node) theEObject; | 221 | Node node = (Node) theEObject; |
216 | T result = caseNode(node); | 222 | T result = caseNode(node); |
217 | if (result == null) | 223 | if (result == null) |
224 | result = caseVariableOrNode(node); | ||
225 | if (result == null) | ||
218 | result = caseNamedElement(node); | 226 | result = caseNamedElement(node); |
219 | if (result == null) | 227 | if (result == null) |
220 | result = defaultCase(theEObject); | 228 | result = defaultCase(theEObject); |
@@ -284,6 +292,28 @@ public class ProblemSwitch<T> extends Switch<T> { | |||
284 | result = defaultCase(theEObject); | 292 | result = defaultCase(theEObject); |
285 | return result; | 293 | return result; |
286 | } | 294 | } |
295 | case ProblemPackage.ENUM_DECLARATION: { | ||
296 | EnumDeclaration enumDeclaration = (EnumDeclaration) theEObject; | ||
297 | T result = caseEnumDeclaration(enumDeclaration); | ||
298 | if (result == null) | ||
299 | result = caseRelation(enumDeclaration); | ||
300 | if (result == null) | ||
301 | result = caseStatement(enumDeclaration); | ||
302 | if (result == null) | ||
303 | result = caseNamedElement(enumDeclaration); | ||
304 | if (result == null) | ||
305 | result = defaultCase(theEObject); | ||
306 | return result; | ||
307 | } | ||
308 | case ProblemPackage.VARIABLE_OR_NODE: { | ||
309 | VariableOrNode variableOrNode = (VariableOrNode) theEObject; | ||
310 | T result = caseVariableOrNode(variableOrNode); | ||
311 | if (result == null) | ||
312 | result = caseNamedElement(variableOrNode); | ||
313 | if (result == null) | ||
314 | result = defaultCase(theEObject); | ||
315 | return result; | ||
316 | } | ||
287 | default: | 317 | default: |
288 | return defaultCase(theEObject); | 318 | return defaultCase(theEObject); |
289 | } | 319 | } |
@@ -650,6 +680,36 @@ public class ProblemSwitch<T> extends Switch<T> { | |||
650 | } | 680 | } |
651 | 681 | ||
652 | /** | 682 | /** |
683 | * Returns the result of interpreting the object as an instance of '<em>Enum Declaration</em>'. | ||
684 | * <!-- begin-user-doc --> | ||
685 | * This implementation returns null; | ||
686 | * returning a non-null result will terminate the switch. | ||
687 | * <!-- end-user-doc --> | ||
688 | * @param object the target of the switch. | ||
689 | * @return the result of interpreting the object as an instance of '<em>Enum Declaration</em>'. | ||
690 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
691 | * @generated | ||
692 | */ | ||
693 | public T caseEnumDeclaration(EnumDeclaration object) { | ||
694 | return null; | ||
695 | } | ||
696 | |||
697 | /** | ||
698 | * Returns the result of interpreting the object as an instance of '<em>Variable Or Node</em>'. | ||
699 | * <!-- begin-user-doc --> | ||
700 | * This implementation returns null; | ||
701 | * returning a non-null result will terminate the switch. | ||
702 | * <!-- end-user-doc --> | ||
703 | * @param object the target of the switch. | ||
704 | * @return the result of interpreting the object as an instance of '<em>Variable Or Node</em>'. | ||
705 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
706 | * @generated | ||
707 | */ | ||
708 | public T caseVariableOrNode(VariableOrNode object) { | ||
709 | return null; | ||
710 | } | ||
711 | |||
712 | /** | ||
653 | * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. | 713 | * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. |
654 | * <!-- begin-user-doc --> | 714 | * <!-- begin-user-doc --> |
655 | * This implementation returns null; | 715 | * This implementation returns null; |