diff options
author | 2021-06-27 01:43:59 +0200 | |
---|---|---|
committer | 2021-06-27 02:01:19 +0200 | |
commit | b88c842ba625753ea185e6166cd967e694160798 (patch) | |
tree | 51931f892dff12d253f7697179e137bdfe705155 /org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources | |
parent | Opposite reference scope (diff) | |
download | refinery-b88c842ba625753ea185e6166cd967e694160798.tar.gz refinery-b88c842ba625753ea185e6166cd967e694160798.tar.zst refinery-b88c842ba625753ea185e6166cd967e694160798.zip |
Add enum support
Diffstat (limited to 'org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources')
2 files changed, 16 insertions, 7 deletions
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.ecore b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.ecore index dd52134b..99404f61 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.ecore +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.ecore | |||
@@ -12,14 +12,14 @@ | |||
12 | <eClassifiers xsi:type="ecore:EClass" name="ClassDeclaration" eSuperTypes="#//Relation #//Statement"> | 12 | <eClassifiers xsi:type="ecore:EClass" name="ClassDeclaration" eSuperTypes="#//Relation #//Statement"> |
13 | <eStructuralFeatures xsi:type="ecore:EAttribute" name="abstract" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"/> | 13 | <eStructuralFeatures xsi:type="ecore:EAttribute" name="abstract" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"/> |
14 | <eStructuralFeatures xsi:type="ecore:EReference" name="superTypes" upperBound="-1" | 14 | <eStructuralFeatures xsi:type="ecore:EReference" name="superTypes" upperBound="-1" |
15 | eType="#//ClassDeclaration"/> | 15 | eType="#//Relation"/> |
16 | <eStructuralFeatures xsi:type="ecore:EReference" name="referenceDeclarations" | 16 | <eStructuralFeatures xsi:type="ecore:EReference" name="referenceDeclarations" |
17 | upperBound="-1" eType="#//ReferenceDeclaration" containment="true"/> | 17 | upperBound="-1" eType="#//ReferenceDeclaration" containment="true"/> |
18 | <eStructuralFeatures xsi:type="ecore:EReference" name="newNode" eType="#//Node" | 18 | <eStructuralFeatures xsi:type="ecore:EReference" name="newNode" eType="#//Node" |
19 | containment="true"/> | 19 | containment="true"/> |
20 | </eClassifiers> | 20 | </eClassifiers> |
21 | <eClassifiers xsi:type="ecore:EClass" name="ReferenceDeclaration" eSuperTypes="#//Relation"> | 21 | <eClassifiers xsi:type="ecore:EClass" name="ReferenceDeclaration" eSuperTypes="#//Relation"> |
22 | <eStructuralFeatures xsi:type="ecore:EReference" name="referenceType" eType="#//ClassDeclaration"/> | 22 | <eStructuralFeatures xsi:type="ecore:EReference" name="referenceType" eType="#//Relation"/> |
23 | <eStructuralFeatures xsi:type="ecore:EReference" name="opposite" eType="#//ReferenceDeclaration"/> | 23 | <eStructuralFeatures xsi:type="ecore:EReference" name="opposite" eType="#//ReferenceDeclaration"/> |
24 | <eStructuralFeatures xsi:type="ecore:EAttribute" name="containment" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"/> | 24 | <eStructuralFeatures xsi:type="ecore:EAttribute" name="containment" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"/> |
25 | <eStructuralFeatures xsi:type="ecore:EReference" name="multiplicity" eType="#//Multiplicity" | 25 | <eStructuralFeatures xsi:type="ecore:EReference" name="multiplicity" eType="#//Multiplicity" |
@@ -36,9 +36,9 @@ | |||
36 | eType="#//Conjunction" containment="true"/> | 36 | eType="#//Conjunction" containment="true"/> |
37 | </eClassifiers> | 37 | </eClassifiers> |
38 | <eClassifiers xsi:type="ecore:EClass" name="Parameter" eSuperTypes="#//Variable"> | 38 | <eClassifiers xsi:type="ecore:EClass" name="Parameter" eSuperTypes="#//Variable"> |
39 | <eStructuralFeatures xsi:type="ecore:EReference" name="parameterType" eType="#//ClassDeclaration"/> | 39 | <eStructuralFeatures xsi:type="ecore:EReference" name="parameterType" eType="#//Relation"/> |
40 | </eClassifiers> | 40 | </eClassifiers> |
41 | <eClassifiers xsi:type="ecore:EClass" name="Variable" abstract="true" eSuperTypes="#//NamedElement"/> | 41 | <eClassifiers xsi:type="ecore:EClass" name="Variable" abstract="true" eSuperTypes="#//VariableOrNode"/> |
42 | <eClassifiers xsi:type="ecore:EClass" name="Conjunction" eSuperTypes="#//ExistentialQuantifier"> | 42 | <eClassifiers xsi:type="ecore:EClass" name="Conjunction" eSuperTypes="#//ExistentialQuantifier"> |
43 | <eStructuralFeatures xsi:type="ecore:EReference" name="literals" upperBound="-1" | 43 | <eStructuralFeatures xsi:type="ecore:EReference" name="literals" upperBound="-1" |
44 | eType="#//Literal" containment="true"/> | 44 | eType="#//Literal" containment="true"/> |
@@ -65,7 +65,7 @@ | |||
65 | eType="#//Node"/> | 65 | eType="#//Node"/> |
66 | <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="#//LogicValue"/> | 66 | <eStructuralFeatures xsi:type="ecore:EAttribute" name="value" eType="#//LogicValue"/> |
67 | </eClassifiers> | 67 | </eClassifiers> |
68 | <eClassifiers xsi:type="ecore:EClass" name="Node" eSuperTypes="#//NamedElement"/> | 68 | <eClassifiers xsi:type="ecore:EClass" name="Node" eSuperTypes="#//VariableOrNode"/> |
69 | <eClassifiers xsi:type="ecore:EEnum" name="LogicValue"> | 69 | <eClassifiers xsi:type="ecore:EEnum" name="LogicValue"> |
70 | <eLiterals name="TRUE" literal="TRUE"/> | 70 | <eLiterals name="TRUE" literal="TRUE"/> |
71 | <eLiterals name="FALSE" value="1"/> | 71 | <eLiterals name="FALSE" value="1"/> |
@@ -95,8 +95,13 @@ | |||
95 | </eClassifiers> | 95 | </eClassifiers> |
96 | <eClassifiers xsi:type="ecore:EClass" name="UnboundedMultiplicity" eSuperTypes="#//Multiplicity"/> | 96 | <eClassifiers xsi:type="ecore:EClass" name="UnboundedMultiplicity" eSuperTypes="#//Multiplicity"/> |
97 | <eClassifiers xsi:type="ecore:EClass" name="Argument"> | 97 | <eClassifiers xsi:type="ecore:EClass" name="Argument"> |
98 | <eStructuralFeatures xsi:type="ecore:EReference" name="variable" eType="#//Variable"/> | 98 | <eStructuralFeatures xsi:type="ecore:EReference" name="variableOrNode" eType="#//VariableOrNode"/> |
99 | <eStructuralFeatures xsi:type="ecore:EReference" name="singletonVariable" eType="#//ImplicitVariable" | 99 | <eStructuralFeatures xsi:type="ecore:EReference" name="singletonVariable" eType="#//ImplicitVariable" |
100 | containment="true"/> | 100 | containment="true"/> |
101 | </eClassifiers> | 101 | </eClassifiers> |
102 | <eClassifiers xsi:type="ecore:EClass" name="EnumDeclaration" eSuperTypes="#//Relation #//Statement"> | ||
103 | <eStructuralFeatures xsi:type="ecore:EReference" name="literals" upperBound="-1" | ||
104 | eType="#//Node" containment="true"/> | ||
105 | </eClassifiers> | ||
106 | <eClassifiers xsi:type="ecore:EClass" name="VariableOrNode" abstract="true" eSuperTypes="#//NamedElement"/> | ||
102 | </ecore:EPackage> | 107 | </ecore:EPackage> |
diff --git a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.genmodel b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.genmodel index 379cb028..2eb9a988 100644 --- a/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.genmodel +++ b/org.eclipse.viatra.solver.language.parent/org.eclipse.viatra.solver.language.model/src/main/resources/model/problem.genmodel | |||
@@ -86,8 +86,12 @@ | |||
86 | </genClasses> | 86 | </genClasses> |
87 | <genClasses ecoreClass="problem.ecore#//UnboundedMultiplicity"/> | 87 | <genClasses ecoreClass="problem.ecore#//UnboundedMultiplicity"/> |
88 | <genClasses ecoreClass="problem.ecore#//Argument"> | 88 | <genClasses ecoreClass="problem.ecore#//Argument"> |
89 | <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference problem.ecore#//Argument/variable"/> | 89 | <genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference problem.ecore#//Argument/variableOrNode"/> |
90 | <genFeatures children="true" createChild="true" propertySortChoices="true" ecoreFeature="ecore:EReference problem.ecore#//Argument/singletonVariable"/> | 90 | <genFeatures children="true" createChild="true" propertySortChoices="true" ecoreFeature="ecore:EReference problem.ecore#//Argument/singletonVariable"/> |
91 | </genClasses> | 91 | </genClasses> |
92 | <genClasses ecoreClass="problem.ecore#//EnumDeclaration"> | ||
93 | <genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference problem.ecore#//EnumDeclaration/literals"/> | ||
94 | </genClasses> | ||
95 | <genClasses ecoreClass="problem.ecore#//VariableOrNode"/> | ||
92 | </genPackages> | 96 | </genPackages> |
93 | </genmodel:GenModel> | 97 | </genmodel:GenModel> |