diff options
Diffstat (limited to 'Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/PredicateDefinitionImpl.java')
-rw-r--r-- | Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/PredicateDefinitionImpl.java | 400 |
1 files changed, 0 insertions, 400 deletions
diff --git a/Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/PredicateDefinitionImpl.java b/Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/PredicateDefinitionImpl.java deleted file mode 100644 index 50130f01..00000000 --- a/Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/PredicateDefinitionImpl.java +++ /dev/null | |||
@@ -1,400 +0,0 @@ | |||
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 | |||
14 | import org.eclipse.viatra.solver.language.solverLanguage.Expression; | ||
15 | import org.eclipse.viatra.solver.language.solverLanguage.PredicateDefinition; | ||
16 | import org.eclipse.viatra.solver.language.solverLanguage.SolverLanguagePackage; | ||
17 | |||
18 | /** | ||
19 | * <!-- begin-user-doc --> | ||
20 | * An implementation of the model object '<em><b>Predicate Definition</b></em>'. | ||
21 | * <!-- end-user-doc --> | ||
22 | * <p> | ||
23 | * The following features are implemented: | ||
24 | * </p> | ||
25 | * <ul> | ||
26 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.PredicateDefinitionImpl#getHead <em>Head</em>}</li> | ||
27 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.PredicateDefinitionImpl#getBody <em>Body</em>}</li> | ||
28 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.PredicateDefinitionImpl#isFunctional <em>Functional</em>}</li> | ||
29 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.PredicateDefinitionImpl#isError <em>Error</em>}</li> | ||
30 | * </ul> | ||
31 | * | ||
32 | * @generated | ||
33 | */ | ||
34 | public class PredicateDefinitionImpl extends StatementImpl implements PredicateDefinition | ||
35 | { | ||
36 | /** | ||
37 | * The cached value of the '{@link #getHead() <em>Head</em>}' containment reference. | ||
38 | * <!-- begin-user-doc --> | ||
39 | * <!-- end-user-doc --> | ||
40 | * @see #getHead() | ||
41 | * @generated | ||
42 | * @ordered | ||
43 | */ | ||
44 | protected Expression head; | ||
45 | |||
46 | /** | ||
47 | * The cached value of the '{@link #getBody() <em>Body</em>}' containment reference. | ||
48 | * <!-- begin-user-doc --> | ||
49 | * <!-- end-user-doc --> | ||
50 | * @see #getBody() | ||
51 | * @generated | ||
52 | * @ordered | ||
53 | */ | ||
54 | protected Expression body; | ||
55 | |||
56 | /** | ||
57 | * The default value of the '{@link #isFunctional() <em>Functional</em>}' attribute. | ||
58 | * <!-- begin-user-doc --> | ||
59 | * <!-- end-user-doc --> | ||
60 | * @see #isFunctional() | ||
61 | * @generated | ||
62 | * @ordered | ||
63 | */ | ||
64 | protected static final boolean FUNCTIONAL_EDEFAULT = false; | ||
65 | |||
66 | /** | ||
67 | * The cached value of the '{@link #isFunctional() <em>Functional</em>}' attribute. | ||
68 | * <!-- begin-user-doc --> | ||
69 | * <!-- end-user-doc --> | ||
70 | * @see #isFunctional() | ||
71 | * @generated | ||
72 | * @ordered | ||
73 | */ | ||
74 | protected boolean functional = FUNCTIONAL_EDEFAULT; | ||
75 | |||
76 | /** | ||
77 | * The default value of the '{@link #isError() <em>Error</em>}' attribute. | ||
78 | * <!-- begin-user-doc --> | ||
79 | * <!-- end-user-doc --> | ||
80 | * @see #isError() | ||
81 | * @generated | ||
82 | * @ordered | ||
83 | */ | ||
84 | protected static final boolean ERROR_EDEFAULT = false; | ||
85 | |||
86 | /** | ||
87 | * The cached value of the '{@link #isError() <em>Error</em>}' attribute. | ||
88 | * <!-- begin-user-doc --> | ||
89 | * <!-- end-user-doc --> | ||
90 | * @see #isError() | ||
91 | * @generated | ||
92 | * @ordered | ||
93 | */ | ||
94 | protected boolean error = ERROR_EDEFAULT; | ||
95 | |||
96 | /** | ||
97 | * <!-- begin-user-doc --> | ||
98 | * <!-- end-user-doc --> | ||
99 | * @generated | ||
100 | */ | ||
101 | protected PredicateDefinitionImpl() | ||
102 | { | ||
103 | super(); | ||
104 | } | ||
105 | |||
106 | /** | ||
107 | * <!-- begin-user-doc --> | ||
108 | * <!-- end-user-doc --> | ||
109 | * @generated | ||
110 | */ | ||
111 | @Override | ||
112 | protected EClass eStaticClass() | ||
113 | { | ||
114 | return SolverLanguagePackage.Literals.PREDICATE_DEFINITION; | ||
115 | } | ||
116 | |||
117 | /** | ||
118 | * <!-- begin-user-doc --> | ||
119 | * <!-- end-user-doc --> | ||
120 | * @generated | ||
121 | */ | ||
122 | @Override | ||
123 | public Expression getHead() | ||
124 | { | ||
125 | return head; | ||
126 | } | ||
127 | |||
128 | /** | ||
129 | * <!-- begin-user-doc --> | ||
130 | * <!-- end-user-doc --> | ||
131 | * @generated | ||
132 | */ | ||
133 | public NotificationChain basicSetHead(Expression newHead, NotificationChain msgs) | ||
134 | { | ||
135 | Expression oldHead = head; | ||
136 | head = newHead; | ||
137 | if (eNotificationRequired()) | ||
138 | { | ||
139 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.PREDICATE_DEFINITION__HEAD, oldHead, newHead); | ||
140 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
141 | } | ||
142 | return msgs; | ||
143 | } | ||
144 | |||
145 | /** | ||
146 | * <!-- begin-user-doc --> | ||
147 | * <!-- end-user-doc --> | ||
148 | * @generated | ||
149 | */ | ||
150 | @Override | ||
151 | public void setHead(Expression newHead) | ||
152 | { | ||
153 | if (newHead != head) | ||
154 | { | ||
155 | NotificationChain msgs = null; | ||
156 | if (head != null) | ||
157 | msgs = ((InternalEObject)head).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.PREDICATE_DEFINITION__HEAD, null, msgs); | ||
158 | if (newHead != null) | ||
159 | msgs = ((InternalEObject)newHead).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.PREDICATE_DEFINITION__HEAD, null, msgs); | ||
160 | msgs = basicSetHead(newHead, msgs); | ||
161 | if (msgs != null) msgs.dispatch(); | ||
162 | } | ||
163 | else if (eNotificationRequired()) | ||
164 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.PREDICATE_DEFINITION__HEAD, newHead, newHead)); | ||
165 | } | ||
166 | |||
167 | /** | ||
168 | * <!-- begin-user-doc --> | ||
169 | * <!-- end-user-doc --> | ||
170 | * @generated | ||
171 | */ | ||
172 | @Override | ||
173 | public Expression getBody() | ||
174 | { | ||
175 | return body; | ||
176 | } | ||
177 | |||
178 | /** | ||
179 | * <!-- begin-user-doc --> | ||
180 | * <!-- end-user-doc --> | ||
181 | * @generated | ||
182 | */ | ||
183 | public NotificationChain basicSetBody(Expression newBody, NotificationChain msgs) | ||
184 | { | ||
185 | Expression oldBody = body; | ||
186 | body = newBody; | ||
187 | if (eNotificationRequired()) | ||
188 | { | ||
189 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.PREDICATE_DEFINITION__BODY, oldBody, newBody); | ||
190 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
191 | } | ||
192 | return msgs; | ||
193 | } | ||
194 | |||
195 | /** | ||
196 | * <!-- begin-user-doc --> | ||
197 | * <!-- end-user-doc --> | ||
198 | * @generated | ||
199 | */ | ||
200 | @Override | ||
201 | public void setBody(Expression newBody) | ||
202 | { | ||
203 | if (newBody != body) | ||
204 | { | ||
205 | NotificationChain msgs = null; | ||
206 | if (body != null) | ||
207 | msgs = ((InternalEObject)body).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.PREDICATE_DEFINITION__BODY, null, msgs); | ||
208 | if (newBody != null) | ||
209 | msgs = ((InternalEObject)newBody).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.PREDICATE_DEFINITION__BODY, null, msgs); | ||
210 | msgs = basicSetBody(newBody, msgs); | ||
211 | if (msgs != null) msgs.dispatch(); | ||
212 | } | ||
213 | else if (eNotificationRequired()) | ||
214 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.PREDICATE_DEFINITION__BODY, newBody, newBody)); | ||
215 | } | ||
216 | |||
217 | /** | ||
218 | * <!-- begin-user-doc --> | ||
219 | * <!-- end-user-doc --> | ||
220 | * @generated | ||
221 | */ | ||
222 | @Override | ||
223 | public boolean isFunctional() | ||
224 | { | ||
225 | return functional; | ||
226 | } | ||
227 | |||
228 | /** | ||
229 | * <!-- begin-user-doc --> | ||
230 | * <!-- end-user-doc --> | ||
231 | * @generated | ||
232 | */ | ||
233 | @Override | ||
234 | public void setFunctional(boolean newFunctional) | ||
235 | { | ||
236 | boolean oldFunctional = functional; | ||
237 | functional = newFunctional; | ||
238 | if (eNotificationRequired()) | ||
239 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.PREDICATE_DEFINITION__FUNCTIONAL, oldFunctional, functional)); | ||
240 | } | ||
241 | |||
242 | /** | ||
243 | * <!-- begin-user-doc --> | ||
244 | * <!-- end-user-doc --> | ||
245 | * @generated | ||
246 | */ | ||
247 | @Override | ||
248 | public boolean isError() | ||
249 | { | ||
250 | return error; | ||
251 | } | ||
252 | |||
253 | /** | ||
254 | * <!-- begin-user-doc --> | ||
255 | * <!-- end-user-doc --> | ||
256 | * @generated | ||
257 | */ | ||
258 | @Override | ||
259 | public void setError(boolean newError) | ||
260 | { | ||
261 | boolean oldError = error; | ||
262 | error = newError; | ||
263 | if (eNotificationRequired()) | ||
264 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.PREDICATE_DEFINITION__ERROR, oldError, error)); | ||
265 | } | ||
266 | |||
267 | /** | ||
268 | * <!-- begin-user-doc --> | ||
269 | * <!-- end-user-doc --> | ||
270 | * @generated | ||
271 | */ | ||
272 | @Override | ||
273 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) | ||
274 | { | ||
275 | switch (featureID) | ||
276 | { | ||
277 | case SolverLanguagePackage.PREDICATE_DEFINITION__HEAD: | ||
278 | return basicSetHead(null, msgs); | ||
279 | case SolverLanguagePackage.PREDICATE_DEFINITION__BODY: | ||
280 | return basicSetBody(null, msgs); | ||
281 | } | ||
282 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
283 | } | ||
284 | |||
285 | /** | ||
286 | * <!-- begin-user-doc --> | ||
287 | * <!-- end-user-doc --> | ||
288 | * @generated | ||
289 | */ | ||
290 | @Override | ||
291 | public Object eGet(int featureID, boolean resolve, boolean coreType) | ||
292 | { | ||
293 | switch (featureID) | ||
294 | { | ||
295 | case SolverLanguagePackage.PREDICATE_DEFINITION__HEAD: | ||
296 | return getHead(); | ||
297 | case SolverLanguagePackage.PREDICATE_DEFINITION__BODY: | ||
298 | return getBody(); | ||
299 | case SolverLanguagePackage.PREDICATE_DEFINITION__FUNCTIONAL: | ||
300 | return isFunctional(); | ||
301 | case SolverLanguagePackage.PREDICATE_DEFINITION__ERROR: | ||
302 | return isError(); | ||
303 | } | ||
304 | return super.eGet(featureID, resolve, coreType); | ||
305 | } | ||
306 | |||
307 | /** | ||
308 | * <!-- begin-user-doc --> | ||
309 | * <!-- end-user-doc --> | ||
310 | * @generated | ||
311 | */ | ||
312 | @Override | ||
313 | public void eSet(int featureID, Object newValue) | ||
314 | { | ||
315 | switch (featureID) | ||
316 | { | ||
317 | case SolverLanguagePackage.PREDICATE_DEFINITION__HEAD: | ||
318 | setHead((Expression)newValue); | ||
319 | return; | ||
320 | case SolverLanguagePackage.PREDICATE_DEFINITION__BODY: | ||
321 | setBody((Expression)newValue); | ||
322 | return; | ||
323 | case SolverLanguagePackage.PREDICATE_DEFINITION__FUNCTIONAL: | ||
324 | setFunctional((Boolean)newValue); | ||
325 | return; | ||
326 | case SolverLanguagePackage.PREDICATE_DEFINITION__ERROR: | ||
327 | setError((Boolean)newValue); | ||
328 | return; | ||
329 | } | ||
330 | super.eSet(featureID, newValue); | ||
331 | } | ||
332 | |||
333 | /** | ||
334 | * <!-- begin-user-doc --> | ||
335 | * <!-- end-user-doc --> | ||
336 | * @generated | ||
337 | */ | ||
338 | @Override | ||
339 | public void eUnset(int featureID) | ||
340 | { | ||
341 | switch (featureID) | ||
342 | { | ||
343 | case SolverLanguagePackage.PREDICATE_DEFINITION__HEAD: | ||
344 | setHead((Expression)null); | ||
345 | return; | ||
346 | case SolverLanguagePackage.PREDICATE_DEFINITION__BODY: | ||
347 | setBody((Expression)null); | ||
348 | return; | ||
349 | case SolverLanguagePackage.PREDICATE_DEFINITION__FUNCTIONAL: | ||
350 | setFunctional(FUNCTIONAL_EDEFAULT); | ||
351 | return; | ||
352 | case SolverLanguagePackage.PREDICATE_DEFINITION__ERROR: | ||
353 | setError(ERROR_EDEFAULT); | ||
354 | return; | ||
355 | } | ||
356 | super.eUnset(featureID); | ||
357 | } | ||
358 | |||
359 | /** | ||
360 | * <!-- begin-user-doc --> | ||
361 | * <!-- end-user-doc --> | ||
362 | * @generated | ||
363 | */ | ||
364 | @Override | ||
365 | public boolean eIsSet(int featureID) | ||
366 | { | ||
367 | switch (featureID) | ||
368 | { | ||
369 | case SolverLanguagePackage.PREDICATE_DEFINITION__HEAD: | ||
370 | return head != null; | ||
371 | case SolverLanguagePackage.PREDICATE_DEFINITION__BODY: | ||
372 | return body != null; | ||
373 | case SolverLanguagePackage.PREDICATE_DEFINITION__FUNCTIONAL: | ||
374 | return functional != FUNCTIONAL_EDEFAULT; | ||
375 | case SolverLanguagePackage.PREDICATE_DEFINITION__ERROR: | ||
376 | return error != ERROR_EDEFAULT; | ||
377 | } | ||
378 | return super.eIsSet(featureID); | ||
379 | } | ||
380 | |||
381 | /** | ||
382 | * <!-- begin-user-doc --> | ||
383 | * <!-- end-user-doc --> | ||
384 | * @generated | ||
385 | */ | ||
386 | @Override | ||
387 | public String toString() | ||
388 | { | ||
389 | if (eIsProxy()) return super.toString(); | ||
390 | |||
391 | StringBuilder result = new StringBuilder(super.toString()); | ||
392 | result.append(" (functional: "); | ||
393 | result.append(functional); | ||
394 | result.append(", error: "); | ||
395 | result.append(error); | ||
396 | result.append(')'); | ||
397 | return result.toString(); | ||
398 | } | ||
399 | |||
400 | } //PredicateDefinitionImpl | ||