diff options
author | 2020-05-19 21:18:06 +0200 | |
---|---|---|
committer | 2020-05-19 21:18:06 +0200 | |
commit | b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b (patch) | |
tree | ad3222182065b8fac7d9b3d528c4efabf2aa0dd2 /Application/org.eclipse.viatra.solver.language/ecore-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/LetBindingImpl.java | |
parent | Merge branch 'master' of github.com:viatra/VIATRA-Generator (diff) | |
download | VIATRA-Generator-b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b.tar.gz VIATRA-Generator-b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b.tar.zst VIATRA-Generator-b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b.zip |
Config language WIP
Diffstat (limited to 'Application/org.eclipse.viatra.solver.language/ecore-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/LetBindingImpl.java')
-rw-r--r-- | Application/org.eclipse.viatra.solver.language/ecore-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/LetBindingImpl.java | 248 |
1 files changed, 248 insertions, 0 deletions
diff --git a/Application/org.eclipse.viatra.solver.language/ecore-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/LetBindingImpl.java b/Application/org.eclipse.viatra.solver.language/ecore-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/LetBindingImpl.java new file mode 100644 index 00000000..9788c44d --- /dev/null +++ b/Application/org.eclipse.viatra.solver.language/ecore-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/LetBindingImpl.java | |||
@@ -0,0 +1,248 @@ | |||
1 | /** | ||
2 | * generated by Xtext 2.21.0 | ||
3 | */ | ||
4 | package org.eclipse.viatra.solver.language.solverLanguage.impl; | ||
5 | |||
6 | import org.eclipse.emf.common.notify.Notification; | ||
7 | import org.eclipse.emf.common.notify.NotificationChain; | ||
8 | |||
9 | import org.eclipse.emf.ecore.EClass; | ||
10 | import org.eclipse.emf.ecore.InternalEObject; | ||
11 | |||
12 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
13 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
14 | |||
15 | import org.eclipse.viatra.solver.language.solverLanguage.Expression; | ||
16 | import org.eclipse.viatra.solver.language.solverLanguage.LetBinding; | ||
17 | import org.eclipse.viatra.solver.language.solverLanguage.NamedElement; | ||
18 | import org.eclipse.viatra.solver.language.solverLanguage.SolverLanguagePackage; | ||
19 | |||
20 | /** | ||
21 | * <!-- begin-user-doc --> | ||
22 | * An implementation of the model object '<em><b>Let Binding</b></em>'. | ||
23 | * <!-- end-user-doc --> | ||
24 | * <p> | ||
25 | * The following features are implemented: | ||
26 | * </p> | ||
27 | * <ul> | ||
28 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.LetBindingImpl#getVariable <em>Variable</em>}</li> | ||
29 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.LetBindingImpl#getValue <em>Value</em>}</li> | ||
30 | * </ul> | ||
31 | * | ||
32 | * @generated | ||
33 | */ | ||
34 | public class LetBindingImpl extends MinimalEObjectImpl.Container implements LetBinding { | ||
35 | /** | ||
36 | * The cached value of the '{@link #getVariable() <em>Variable</em>}' containment reference. | ||
37 | * <!-- begin-user-doc --> | ||
38 | * <!-- end-user-doc --> | ||
39 | * @see #getVariable() | ||
40 | * @generated | ||
41 | * @ordered | ||
42 | */ | ||
43 | protected NamedElement variable; | ||
44 | |||
45 | /** | ||
46 | * The cached value of the '{@link #getValue() <em>Value</em>}' containment reference. | ||
47 | * <!-- begin-user-doc --> | ||
48 | * <!-- end-user-doc --> | ||
49 | * @see #getValue() | ||
50 | * @generated | ||
51 | * @ordered | ||
52 | */ | ||
53 | protected Expression value; | ||
54 | |||
55 | /** | ||
56 | * <!-- begin-user-doc --> | ||
57 | * <!-- end-user-doc --> | ||
58 | * @generated | ||
59 | */ | ||
60 | protected LetBindingImpl() { | ||
61 | super(); | ||
62 | } | ||
63 | |||
64 | /** | ||
65 | * <!-- begin-user-doc --> | ||
66 | * <!-- end-user-doc --> | ||
67 | * @generated | ||
68 | */ | ||
69 | @Override | ||
70 | protected EClass eStaticClass() { | ||
71 | return SolverLanguagePackage.Literals.LET_BINDING; | ||
72 | } | ||
73 | |||
74 | /** | ||
75 | * <!-- begin-user-doc --> | ||
76 | * <!-- end-user-doc --> | ||
77 | * @generated | ||
78 | */ | ||
79 | @Override | ||
80 | public NamedElement getVariable() { | ||
81 | return variable; | ||
82 | } | ||
83 | |||
84 | /** | ||
85 | * <!-- begin-user-doc --> | ||
86 | * <!-- end-user-doc --> | ||
87 | * @generated | ||
88 | */ | ||
89 | public NotificationChain basicSetVariable(NamedElement newVariable, NotificationChain msgs) { | ||
90 | NamedElement oldVariable = variable; | ||
91 | variable = newVariable; | ||
92 | if (eNotificationRequired()) { | ||
93 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.LET_BINDING__VARIABLE, oldVariable, newVariable); | ||
94 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
95 | } | ||
96 | return msgs; | ||
97 | } | ||
98 | |||
99 | /** | ||
100 | * <!-- begin-user-doc --> | ||
101 | * <!-- end-user-doc --> | ||
102 | * @generated | ||
103 | */ | ||
104 | @Override | ||
105 | public void setVariable(NamedElement newVariable) { | ||
106 | if (newVariable != variable) { | ||
107 | NotificationChain msgs = null; | ||
108 | if (variable != null) | ||
109 | msgs = ((InternalEObject)variable).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.LET_BINDING__VARIABLE, null, msgs); | ||
110 | if (newVariable != null) | ||
111 | msgs = ((InternalEObject)newVariable).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.LET_BINDING__VARIABLE, null, msgs); | ||
112 | msgs = basicSetVariable(newVariable, msgs); | ||
113 | if (msgs != null) msgs.dispatch(); | ||
114 | } | ||
115 | else if (eNotificationRequired()) | ||
116 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.LET_BINDING__VARIABLE, newVariable, newVariable)); | ||
117 | } | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | @Override | ||
125 | public Expression getValue() { | ||
126 | return value; | ||
127 | } | ||
128 | |||
129 | /** | ||
130 | * <!-- begin-user-doc --> | ||
131 | * <!-- end-user-doc --> | ||
132 | * @generated | ||
133 | */ | ||
134 | public NotificationChain basicSetValue(Expression newValue, NotificationChain msgs) { | ||
135 | Expression oldValue = value; | ||
136 | value = newValue; | ||
137 | if (eNotificationRequired()) { | ||
138 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.LET_BINDING__VALUE, oldValue, newValue); | ||
139 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
140 | } | ||
141 | return msgs; | ||
142 | } | ||
143 | |||
144 | /** | ||
145 | * <!-- begin-user-doc --> | ||
146 | * <!-- end-user-doc --> | ||
147 | * @generated | ||
148 | */ | ||
149 | @Override | ||
150 | public void setValue(Expression newValue) { | ||
151 | if (newValue != value) { | ||
152 | NotificationChain msgs = null; | ||
153 | if (value != null) | ||
154 | msgs = ((InternalEObject)value).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.LET_BINDING__VALUE, null, msgs); | ||
155 | if (newValue != null) | ||
156 | msgs = ((InternalEObject)newValue).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.LET_BINDING__VALUE, null, msgs); | ||
157 | msgs = basicSetValue(newValue, msgs); | ||
158 | if (msgs != null) msgs.dispatch(); | ||
159 | } | ||
160 | else if (eNotificationRequired()) | ||
161 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.LET_BINDING__VALUE, newValue, newValue)); | ||
162 | } | ||
163 | |||
164 | /** | ||
165 | * <!-- begin-user-doc --> | ||
166 | * <!-- end-user-doc --> | ||
167 | * @generated | ||
168 | */ | ||
169 | @Override | ||
170 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
171 | switch (featureID) { | ||
172 | case SolverLanguagePackage.LET_BINDING__VARIABLE: | ||
173 | return basicSetVariable(null, msgs); | ||
174 | case SolverLanguagePackage.LET_BINDING__VALUE: | ||
175 | return basicSetValue(null, msgs); | ||
176 | } | ||
177 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
178 | } | ||
179 | |||
180 | /** | ||
181 | * <!-- begin-user-doc --> | ||
182 | * <!-- end-user-doc --> | ||
183 | * @generated | ||
184 | */ | ||
185 | @Override | ||
186 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
187 | switch (featureID) { | ||
188 | case SolverLanguagePackage.LET_BINDING__VARIABLE: | ||
189 | return getVariable(); | ||
190 | case SolverLanguagePackage.LET_BINDING__VALUE: | ||
191 | return getValue(); | ||
192 | } | ||
193 | return super.eGet(featureID, resolve, coreType); | ||
194 | } | ||
195 | |||
196 | /** | ||
197 | * <!-- begin-user-doc --> | ||
198 | * <!-- end-user-doc --> | ||
199 | * @generated | ||
200 | */ | ||
201 | @Override | ||
202 | public void eSet(int featureID, Object newValue) { | ||
203 | switch (featureID) { | ||
204 | case SolverLanguagePackage.LET_BINDING__VARIABLE: | ||
205 | setVariable((NamedElement)newValue); | ||
206 | return; | ||
207 | case SolverLanguagePackage.LET_BINDING__VALUE: | ||
208 | setValue((Expression)newValue); | ||
209 | return; | ||
210 | } | ||
211 | super.eSet(featureID, newValue); | ||
212 | } | ||
213 | |||
214 | /** | ||
215 | * <!-- begin-user-doc --> | ||
216 | * <!-- end-user-doc --> | ||
217 | * @generated | ||
218 | */ | ||
219 | @Override | ||
220 | public void eUnset(int featureID) { | ||
221 | switch (featureID) { | ||
222 | case SolverLanguagePackage.LET_BINDING__VARIABLE: | ||
223 | setVariable((NamedElement)null); | ||
224 | return; | ||
225 | case SolverLanguagePackage.LET_BINDING__VALUE: | ||
226 | setValue((Expression)null); | ||
227 | return; | ||
228 | } | ||
229 | super.eUnset(featureID); | ||
230 | } | ||
231 | |||
232 | /** | ||
233 | * <!-- begin-user-doc --> | ||
234 | * <!-- end-user-doc --> | ||
235 | * @generated | ||
236 | */ | ||
237 | @Override | ||
238 | public boolean eIsSet(int featureID) { | ||
239 | switch (featureID) { | ||
240 | case SolverLanguagePackage.LET_BINDING__VARIABLE: | ||
241 | return variable != null; | ||
242 | case SolverLanguagePackage.LET_BINDING__VALUE: | ||
243 | return value != null; | ||
244 | } | ||
245 | return super.eIsSet(featureID); | ||
246 | } | ||
247 | |||
248 | } //LetBindingImpl | ||