diff options
author | 2020-04-26 18:23:13 -0400 | |
---|---|---|
committer | 2020-04-26 18:23:13 -0400 | |
commit | c0a758eedd457a5d8eb9f1a6c17fc24143aabb3e (patch) | |
tree | 0c2e212e4e95c1d2311629128641d5cd561210f3 /Tests/MODELS2020-CaseStudies/case.study.pledge.model/src/Taxation/impl/DependentImpl.java | |
parent | Merge branch 'Attribute-Solver' (diff) | |
download | VIATRA-Generator-c0a758eedd457a5d8eb9f1a6c17fc24143aabb3e.tar.gz VIATRA-Generator-c0a758eedd457a5d8eb9f1a6c17fc24143aabb3e.tar.zst VIATRA-Generator-c0a758eedd457a5d8eb9f1a6c17fc24143aabb3e.zip |
Add PLEDGE case study files
Diffstat (limited to 'Tests/MODELS2020-CaseStudies/case.study.pledge.model/src/Taxation/impl/DependentImpl.java')
-rw-r--r-- | Tests/MODELS2020-CaseStudies/case.study.pledge.model/src/Taxation/impl/DependentImpl.java | 598 |
1 files changed, 598 insertions, 0 deletions
diff --git a/Tests/MODELS2020-CaseStudies/case.study.pledge.model/src/Taxation/impl/DependentImpl.java b/Tests/MODELS2020-CaseStudies/case.study.pledge.model/src/Taxation/impl/DependentImpl.java new file mode 100644 index 00000000..0732ae44 --- /dev/null +++ b/Tests/MODELS2020-CaseStudies/case.study.pledge.model/src/Taxation/impl/DependentImpl.java | |||
@@ -0,0 +1,598 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package Taxation.impl; | ||
4 | |||
5 | import Taxation.Dependent; | ||
6 | import Taxation.Dependent_Type; | ||
7 | import Taxation.Expense; | ||
8 | import Taxation.External_Allowance; | ||
9 | import Taxation.FromAgent; | ||
10 | import Taxation.Household; | ||
11 | import Taxation.Tax_Payer; | ||
12 | import Taxation.TaxationPackage; | ||
13 | |||
14 | import java.util.Collection; | ||
15 | |||
16 | import org.eclipse.emf.common.notify.Notification; | ||
17 | import org.eclipse.emf.common.notify.NotificationChain; | ||
18 | |||
19 | import org.eclipse.emf.common.util.EList; | ||
20 | |||
21 | import org.eclipse.emf.ecore.EClass; | ||
22 | import org.eclipse.emf.ecore.InternalEObject; | ||
23 | |||
24 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
25 | import org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList; | ||
26 | import org.eclipse.emf.ecore.util.EcoreUtil; | ||
27 | import org.eclipse.emf.ecore.util.InternalEList; | ||
28 | |||
29 | /** | ||
30 | * <!-- begin-user-doc --> | ||
31 | * An implementation of the model object '<em><b>Dependent</b></em>'. | ||
32 | * <!-- end-user-doc --> | ||
33 | * <p> | ||
34 | * The following features are implemented: | ||
35 | * </p> | ||
36 | * <ul> | ||
37 | * <li>{@link Taxation.impl.DependentImpl#getDependent_type <em>Dependent type</em>}</li> | ||
38 | * <li>{@link Taxation.impl.DependentImpl#getResponsible_person <em>Responsible person</em>}</li> | ||
39 | * <li>{@link Taxation.impl.DependentImpl#isContinued_studies <em>Continued studies</em>}</li> | ||
40 | * <li>{@link Taxation.impl.DependentImpl#getAllowances <em>Allowances</em>}</li> | ||
41 | * <li>{@link Taxation.impl.DependentImpl#getHousehold <em>Household</em>}</li> | ||
42 | * <li>{@link Taxation.impl.DependentImpl#getFrom_agent <em>From agent</em>}</li> | ||
43 | * <li>{@link Taxation.impl.DependentImpl#getExpense <em>Expense</em>}</li> | ||
44 | * </ul> | ||
45 | * | ||
46 | * @generated | ||
47 | */ | ||
48 | public class DependentImpl extends Physical_PersonImpl implements Dependent { | ||
49 | /** | ||
50 | * The default value of the '{@link #getDependent_type() <em>Dependent type</em>}' attribute. | ||
51 | * <!-- begin-user-doc --> | ||
52 | * <!-- end-user-doc --> | ||
53 | * @see #getDependent_type() | ||
54 | * @generated | ||
55 | * @ordered | ||
56 | */ | ||
57 | protected static final Dependent_Type DEPENDENT_TYPE_EDEFAULT = Dependent_Type.CHILD; | ||
58 | |||
59 | /** | ||
60 | * The cached value of the '{@link #getDependent_type() <em>Dependent type</em>}' attribute. | ||
61 | * <!-- begin-user-doc --> | ||
62 | * <!-- end-user-doc --> | ||
63 | * @see #getDependent_type() | ||
64 | * @generated | ||
65 | * @ordered | ||
66 | */ | ||
67 | protected Dependent_Type dependent_type = DEPENDENT_TYPE_EDEFAULT; | ||
68 | |||
69 | /** | ||
70 | * The default value of the '{@link #isContinued_studies() <em>Continued studies</em>}' attribute. | ||
71 | * <!-- begin-user-doc --> | ||
72 | * <!-- end-user-doc --> | ||
73 | * @see #isContinued_studies() | ||
74 | * @generated | ||
75 | * @ordered | ||
76 | */ | ||
77 | protected static final boolean CONTINUED_STUDIES_EDEFAULT = false; | ||
78 | |||
79 | /** | ||
80 | * The cached value of the '{@link #isContinued_studies() <em>Continued studies</em>}' attribute. | ||
81 | * <!-- begin-user-doc --> | ||
82 | * <!-- end-user-doc --> | ||
83 | * @see #isContinued_studies() | ||
84 | * @generated | ||
85 | * @ordered | ||
86 | */ | ||
87 | protected boolean continued_studies = CONTINUED_STUDIES_EDEFAULT; | ||
88 | |||
89 | /** | ||
90 | * The cached value of the '{@link #getAllowances() <em>Allowances</em>}' containment reference. | ||
91 | * <!-- begin-user-doc --> | ||
92 | * <!-- end-user-doc --> | ||
93 | * @see #getAllowances() | ||
94 | * @generated | ||
95 | * @ordered | ||
96 | */ | ||
97 | protected External_Allowance allowances; | ||
98 | |||
99 | /** | ||
100 | * The cached value of the '{@link #getFrom_agent() <em>From agent</em>}' reference. | ||
101 | * <!-- begin-user-doc --> | ||
102 | * <!-- end-user-doc --> | ||
103 | * @see #getFrom_agent() | ||
104 | * @generated | ||
105 | * @ordered | ||
106 | */ | ||
107 | protected FromAgent from_agent; | ||
108 | |||
109 | /** | ||
110 | * The cached value of the '{@link #getExpense() <em>Expense</em>}' reference list. | ||
111 | * <!-- begin-user-doc --> | ||
112 | * <!-- end-user-doc --> | ||
113 | * @see #getExpense() | ||
114 | * @generated | ||
115 | * @ordered | ||
116 | */ | ||
117 | protected EList<Expense> expense; | ||
118 | |||
119 | /** | ||
120 | * <!-- begin-user-doc --> | ||
121 | * <!-- end-user-doc --> | ||
122 | * @generated | ||
123 | */ | ||
124 | protected DependentImpl() { | ||
125 | super(); | ||
126 | } | ||
127 | |||
128 | /** | ||
129 | * <!-- begin-user-doc --> | ||
130 | * <!-- end-user-doc --> | ||
131 | * @generated | ||
132 | */ | ||
133 | @Override | ||
134 | protected EClass eStaticClass() { | ||
135 | return TaxationPackage.Literals.DEPENDENT; | ||
136 | } | ||
137 | |||
138 | /** | ||
139 | * <!-- begin-user-doc --> | ||
140 | * <!-- end-user-doc --> | ||
141 | * @generated | ||
142 | */ | ||
143 | @Override | ||
144 | public Dependent_Type getDependent_type() { | ||
145 | return dependent_type; | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * <!-- begin-user-doc --> | ||
150 | * <!-- end-user-doc --> | ||
151 | * @generated | ||
152 | */ | ||
153 | @Override | ||
154 | public void setDependent_type(Dependent_Type newDependent_type) { | ||
155 | Dependent_Type oldDependent_type = dependent_type; | ||
156 | dependent_type = newDependent_type == null ? DEPENDENT_TYPE_EDEFAULT : newDependent_type; | ||
157 | if (eNotificationRequired()) | ||
158 | eNotify(new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__DEPENDENT_TYPE, oldDependent_type, dependent_type)); | ||
159 | } | ||
160 | |||
161 | /** | ||
162 | * <!-- begin-user-doc --> | ||
163 | * <!-- end-user-doc --> | ||
164 | * @generated | ||
165 | */ | ||
166 | @Override | ||
167 | public Tax_Payer getResponsible_person() { | ||
168 | if (eContainerFeatureID() != TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON) return null; | ||
169 | return (Tax_Payer)eInternalContainer(); | ||
170 | } | ||
171 | |||
172 | /** | ||
173 | * <!-- begin-user-doc --> | ||
174 | * <!-- end-user-doc --> | ||
175 | * @generated | ||
176 | */ | ||
177 | public NotificationChain basicSetResponsible_person(Tax_Payer newResponsible_person, NotificationChain msgs) { | ||
178 | msgs = eBasicSetContainer((InternalEObject)newResponsible_person, TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON, msgs); | ||
179 | return msgs; | ||
180 | } | ||
181 | |||
182 | /** | ||
183 | * <!-- begin-user-doc --> | ||
184 | * <!-- end-user-doc --> | ||
185 | * @generated | ||
186 | */ | ||
187 | @Override | ||
188 | public void setResponsible_person(Tax_Payer newResponsible_person) { | ||
189 | if (newResponsible_person != eInternalContainer() || (eContainerFeatureID() != TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON && newResponsible_person != null)) { | ||
190 | if (EcoreUtil.isAncestor(this, newResponsible_person)) | ||
191 | throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); | ||
192 | NotificationChain msgs = null; | ||
193 | if (eInternalContainer() != null) | ||
194 | msgs = eBasicRemoveFromContainer(msgs); | ||
195 | if (newResponsible_person != null) | ||
196 | msgs = ((InternalEObject)newResponsible_person).eInverseAdd(this, TaxationPackage.TAX_PAYER__DEPENDENTS, Tax_Payer.class, msgs); | ||
197 | msgs = basicSetResponsible_person(newResponsible_person, msgs); | ||
198 | if (msgs != null) msgs.dispatch(); | ||
199 | } | ||
200 | else if (eNotificationRequired()) | ||
201 | eNotify(new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON, newResponsible_person, newResponsible_person)); | ||
202 | } | ||
203 | |||
204 | /** | ||
205 | * <!-- begin-user-doc --> | ||
206 | * <!-- end-user-doc --> | ||
207 | * @generated | ||
208 | */ | ||
209 | @Override | ||
210 | public boolean isContinued_studies() { | ||
211 | return continued_studies; | ||
212 | } | ||
213 | |||
214 | /** | ||
215 | * <!-- begin-user-doc --> | ||
216 | * <!-- end-user-doc --> | ||
217 | * @generated | ||
218 | */ | ||
219 | @Override | ||
220 | public void setContinued_studies(boolean newContinued_studies) { | ||
221 | boolean oldContinued_studies = continued_studies; | ||
222 | continued_studies = newContinued_studies; | ||
223 | if (eNotificationRequired()) | ||
224 | eNotify(new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__CONTINUED_STUDIES, oldContinued_studies, continued_studies)); | ||
225 | } | ||
226 | |||
227 | /** | ||
228 | * <!-- begin-user-doc --> | ||
229 | * <!-- end-user-doc --> | ||
230 | * @generated | ||
231 | */ | ||
232 | @Override | ||
233 | public External_Allowance getAllowances() { | ||
234 | return allowances; | ||
235 | } | ||
236 | |||
237 | /** | ||
238 | * <!-- begin-user-doc --> | ||
239 | * <!-- end-user-doc --> | ||
240 | * @generated | ||
241 | */ | ||
242 | public NotificationChain basicSetAllowances(External_Allowance newAllowances, NotificationChain msgs) { | ||
243 | External_Allowance oldAllowances = allowances; | ||
244 | allowances = newAllowances; | ||
245 | if (eNotificationRequired()) { | ||
246 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__ALLOWANCES, oldAllowances, newAllowances); | ||
247 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
248 | } | ||
249 | return msgs; | ||
250 | } | ||
251 | |||
252 | /** | ||
253 | * <!-- begin-user-doc --> | ||
254 | * <!-- end-user-doc --> | ||
255 | * @generated | ||
256 | */ | ||
257 | @Override | ||
258 | public void setAllowances(External_Allowance newAllowances) { | ||
259 | if (newAllowances != allowances) { | ||
260 | NotificationChain msgs = null; | ||
261 | if (allowances != null) | ||
262 | msgs = ((InternalEObject)allowances).eInverseRemove(this, TaxationPackage.EXTERNAL_ALLOWANCE__PERSON, External_Allowance.class, msgs); | ||
263 | if (newAllowances != null) | ||
264 | msgs = ((InternalEObject)newAllowances).eInverseAdd(this, TaxationPackage.EXTERNAL_ALLOWANCE__PERSON, External_Allowance.class, msgs); | ||
265 | msgs = basicSetAllowances(newAllowances, msgs); | ||
266 | if (msgs != null) msgs.dispatch(); | ||
267 | } | ||
268 | else if (eNotificationRequired()) | ||
269 | eNotify(new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__ALLOWANCES, newAllowances, newAllowances)); | ||
270 | } | ||
271 | |||
272 | /** | ||
273 | * <!-- begin-user-doc --> | ||
274 | * <!-- end-user-doc --> | ||
275 | * @generated | ||
276 | */ | ||
277 | @Override | ||
278 | public Household getHousehold() { | ||
279 | if (eContainerFeatureID() != TaxationPackage.DEPENDENT__HOUSEHOLD) return null; | ||
280 | return (Household)eInternalContainer(); | ||
281 | } | ||
282 | |||
283 | /** | ||
284 | * <!-- begin-user-doc --> | ||
285 | * <!-- end-user-doc --> | ||
286 | * @generated | ||
287 | */ | ||
288 | public NotificationChain basicSetHousehold(Household newHousehold, NotificationChain msgs) { | ||
289 | msgs = eBasicSetContainer((InternalEObject)newHousehold, TaxationPackage.DEPENDENT__HOUSEHOLD, msgs); | ||
290 | return msgs; | ||
291 | } | ||
292 | |||
293 | /** | ||
294 | * <!-- begin-user-doc --> | ||
295 | * <!-- end-user-doc --> | ||
296 | * @generated | ||
297 | */ | ||
298 | @Override | ||
299 | public void setHousehold(Household newHousehold) { | ||
300 | if (newHousehold != eInternalContainer() || (eContainerFeatureID() != TaxationPackage.DEPENDENT__HOUSEHOLD && newHousehold != null)) { | ||
301 | if (EcoreUtil.isAncestor(this, newHousehold)) | ||
302 | throw new IllegalArgumentException("Recursive containment not allowed for " + toString()); | ||
303 | NotificationChain msgs = null; | ||
304 | if (eInternalContainer() != null) | ||
305 | msgs = eBasicRemoveFromContainer(msgs); | ||
306 | if (newHousehold != null) | ||
307 | msgs = ((InternalEObject)newHousehold).eInverseAdd(this, TaxationPackage.HOUSEHOLD__CHILDREN, Household.class, msgs); | ||
308 | msgs = basicSetHousehold(newHousehold, msgs); | ||
309 | if (msgs != null) msgs.dispatch(); | ||
310 | } | ||
311 | else if (eNotificationRequired()) | ||
312 | eNotify(new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__HOUSEHOLD, newHousehold, newHousehold)); | ||
313 | } | ||
314 | |||
315 | /** | ||
316 | * <!-- begin-user-doc --> | ||
317 | * <!-- end-user-doc --> | ||
318 | * @generated | ||
319 | */ | ||
320 | @Override | ||
321 | public FromAgent getFrom_agent() { | ||
322 | if (from_agent != null && from_agent.eIsProxy()) { | ||
323 | InternalEObject oldFrom_agent = (InternalEObject)from_agent; | ||
324 | from_agent = (FromAgent)eResolveProxy(oldFrom_agent); | ||
325 | if (from_agent != oldFrom_agent) { | ||
326 | if (eNotificationRequired()) | ||
327 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, TaxationPackage.DEPENDENT__FROM_AGENT, oldFrom_agent, from_agent)); | ||
328 | } | ||
329 | } | ||
330 | return from_agent; | ||
331 | } | ||
332 | |||
333 | /** | ||
334 | * <!-- begin-user-doc --> | ||
335 | * <!-- end-user-doc --> | ||
336 | * @generated | ||
337 | */ | ||
338 | public FromAgent basicGetFrom_agent() { | ||
339 | return from_agent; | ||
340 | } | ||
341 | |||
342 | /** | ||
343 | * <!-- begin-user-doc --> | ||
344 | * <!-- end-user-doc --> | ||
345 | * @generated | ||
346 | */ | ||
347 | public NotificationChain basicSetFrom_agent(FromAgent newFrom_agent, NotificationChain msgs) { | ||
348 | FromAgent oldFrom_agent = from_agent; | ||
349 | from_agent = newFrom_agent; | ||
350 | if (eNotificationRequired()) { | ||
351 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__FROM_AGENT, oldFrom_agent, newFrom_agent); | ||
352 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
353 | } | ||
354 | return msgs; | ||
355 | } | ||
356 | |||
357 | /** | ||
358 | * <!-- begin-user-doc --> | ||
359 | * <!-- end-user-doc --> | ||
360 | * @generated | ||
361 | */ | ||
362 | @Override | ||
363 | public void setFrom_agent(FromAgent newFrom_agent) { | ||
364 | if (newFrom_agent != from_agent) { | ||
365 | NotificationChain msgs = null; | ||
366 | if (from_agent != null) | ||
367 | msgs = ((InternalEObject)from_agent).eInverseRemove(this, TaxationPackage.FROM_AGENT__DEPENDENT, FromAgent.class, msgs); | ||
368 | if (newFrom_agent != null) | ||
369 | msgs = ((InternalEObject)newFrom_agent).eInverseAdd(this, TaxationPackage.FROM_AGENT__DEPENDENT, FromAgent.class, msgs); | ||
370 | msgs = basicSetFrom_agent(newFrom_agent, msgs); | ||
371 | if (msgs != null) msgs.dispatch(); | ||
372 | } | ||
373 | else if (eNotificationRequired()) | ||
374 | eNotify(new ENotificationImpl(this, Notification.SET, TaxationPackage.DEPENDENT__FROM_AGENT, newFrom_agent, newFrom_agent)); | ||
375 | } | ||
376 | |||
377 | /** | ||
378 | * <!-- begin-user-doc --> | ||
379 | * <!-- end-user-doc --> | ||
380 | * @generated | ||
381 | */ | ||
382 | @Override | ||
383 | public EList<Expense> getExpense() { | ||
384 | if (expense == null) { | ||
385 | expense = new EObjectWithInverseResolvingEList<Expense>(Expense.class, this, TaxationPackage.DEPENDENT__EXPENSE, TaxationPackage.EXPENSE__DEPENDENT); | ||
386 | } | ||
387 | return expense; | ||
388 | } | ||
389 | |||
390 | /** | ||
391 | * <!-- begin-user-doc --> | ||
392 | * <!-- end-user-doc --> | ||
393 | * @generated | ||
394 | */ | ||
395 | @SuppressWarnings("unchecked") | ||
396 | @Override | ||
397 | public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
398 | switch (featureID) { | ||
399 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
400 | if (eInternalContainer() != null) | ||
401 | msgs = eBasicRemoveFromContainer(msgs); | ||
402 | return basicSetResponsible_person((Tax_Payer)otherEnd, msgs); | ||
403 | case TaxationPackage.DEPENDENT__ALLOWANCES: | ||
404 | if (allowances != null) | ||
405 | msgs = ((InternalEObject)allowances).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - TaxationPackage.DEPENDENT__ALLOWANCES, null, msgs); | ||
406 | return basicSetAllowances((External_Allowance)otherEnd, msgs); | ||
407 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
408 | if (eInternalContainer() != null) | ||
409 | msgs = eBasicRemoveFromContainer(msgs); | ||
410 | return basicSetHousehold((Household)otherEnd, msgs); | ||
411 | case TaxationPackage.DEPENDENT__FROM_AGENT: | ||
412 | if (from_agent != null) | ||
413 | msgs = ((InternalEObject)from_agent).eInverseRemove(this, TaxationPackage.FROM_AGENT__DEPENDENT, FromAgent.class, msgs); | ||
414 | return basicSetFrom_agent((FromAgent)otherEnd, msgs); | ||
415 | case TaxationPackage.DEPENDENT__EXPENSE: | ||
416 | return ((InternalEList<InternalEObject>)(InternalEList<?>)getExpense()).basicAdd(otherEnd, msgs); | ||
417 | } | ||
418 | return super.eInverseAdd(otherEnd, featureID, msgs); | ||
419 | } | ||
420 | |||
421 | /** | ||
422 | * <!-- begin-user-doc --> | ||
423 | * <!-- end-user-doc --> | ||
424 | * @generated | ||
425 | */ | ||
426 | @Override | ||
427 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
428 | switch (featureID) { | ||
429 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
430 | return basicSetResponsible_person(null, msgs); | ||
431 | case TaxationPackage.DEPENDENT__ALLOWANCES: | ||
432 | return basicSetAllowances(null, msgs); | ||
433 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
434 | return basicSetHousehold(null, msgs); | ||
435 | case TaxationPackage.DEPENDENT__FROM_AGENT: | ||
436 | return basicSetFrom_agent(null, msgs); | ||
437 | case TaxationPackage.DEPENDENT__EXPENSE: | ||
438 | return ((InternalEList<?>)getExpense()).basicRemove(otherEnd, msgs); | ||
439 | } | ||
440 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
441 | } | ||
442 | |||
443 | /** | ||
444 | * <!-- begin-user-doc --> | ||
445 | * <!-- end-user-doc --> | ||
446 | * @generated | ||
447 | */ | ||
448 | @Override | ||
449 | public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) { | ||
450 | switch (eContainerFeatureID()) { | ||
451 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
452 | return eInternalContainer().eInverseRemove(this, TaxationPackage.TAX_PAYER__DEPENDENTS, Tax_Payer.class, msgs); | ||
453 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
454 | return eInternalContainer().eInverseRemove(this, TaxationPackage.HOUSEHOLD__CHILDREN, Household.class, msgs); | ||
455 | } | ||
456 | return super.eBasicRemoveFromContainerFeature(msgs); | ||
457 | } | ||
458 | |||
459 | /** | ||
460 | * <!-- begin-user-doc --> | ||
461 | * <!-- end-user-doc --> | ||
462 | * @generated | ||
463 | */ | ||
464 | @Override | ||
465 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
466 | switch (featureID) { | ||
467 | case TaxationPackage.DEPENDENT__DEPENDENT_TYPE: | ||
468 | return getDependent_type(); | ||
469 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
470 | return getResponsible_person(); | ||
471 | case TaxationPackage.DEPENDENT__CONTINUED_STUDIES: | ||
472 | return isContinued_studies(); | ||
473 | case TaxationPackage.DEPENDENT__ALLOWANCES: | ||
474 | return getAllowances(); | ||
475 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
476 | return getHousehold(); | ||
477 | case TaxationPackage.DEPENDENT__FROM_AGENT: | ||
478 | if (resolve) return getFrom_agent(); | ||
479 | return basicGetFrom_agent(); | ||
480 | case TaxationPackage.DEPENDENT__EXPENSE: | ||
481 | return getExpense(); | ||
482 | } | ||
483 | return super.eGet(featureID, resolve, coreType); | ||
484 | } | ||
485 | |||
486 | /** | ||
487 | * <!-- begin-user-doc --> | ||
488 | * <!-- end-user-doc --> | ||
489 | * @generated | ||
490 | */ | ||
491 | @SuppressWarnings("unchecked") | ||
492 | @Override | ||
493 | public void eSet(int featureID, Object newValue) { | ||
494 | switch (featureID) { | ||
495 | case TaxationPackage.DEPENDENT__DEPENDENT_TYPE: | ||
496 | setDependent_type((Dependent_Type)newValue); | ||
497 | return; | ||
498 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
499 | setResponsible_person((Tax_Payer)newValue); | ||
500 | return; | ||
501 | case TaxationPackage.DEPENDENT__CONTINUED_STUDIES: | ||
502 | setContinued_studies((Boolean)newValue); | ||
503 | return; | ||
504 | case TaxationPackage.DEPENDENT__ALLOWANCES: | ||
505 | setAllowances((External_Allowance)newValue); | ||
506 | return; | ||
507 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
508 | setHousehold((Household)newValue); | ||
509 | return; | ||
510 | case TaxationPackage.DEPENDENT__FROM_AGENT: | ||
511 | setFrom_agent((FromAgent)newValue); | ||
512 | return; | ||
513 | case TaxationPackage.DEPENDENT__EXPENSE: | ||
514 | getExpense().clear(); | ||
515 | getExpense().addAll((Collection<? extends Expense>)newValue); | ||
516 | return; | ||
517 | } | ||
518 | super.eSet(featureID, newValue); | ||
519 | } | ||
520 | |||
521 | /** | ||
522 | * <!-- begin-user-doc --> | ||
523 | * <!-- end-user-doc --> | ||
524 | * @generated | ||
525 | */ | ||
526 | @Override | ||
527 | public void eUnset(int featureID) { | ||
528 | switch (featureID) { | ||
529 | case TaxationPackage.DEPENDENT__DEPENDENT_TYPE: | ||
530 | setDependent_type(DEPENDENT_TYPE_EDEFAULT); | ||
531 | return; | ||
532 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
533 | setResponsible_person((Tax_Payer)null); | ||
534 | return; | ||
535 | case TaxationPackage.DEPENDENT__CONTINUED_STUDIES: | ||
536 | setContinued_studies(CONTINUED_STUDIES_EDEFAULT); | ||
537 | return; | ||
538 | case TaxationPackage.DEPENDENT__ALLOWANCES: | ||
539 | setAllowances((External_Allowance)null); | ||
540 | return; | ||
541 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
542 | setHousehold((Household)null); | ||
543 | return; | ||
544 | case TaxationPackage.DEPENDENT__FROM_AGENT: | ||
545 | setFrom_agent((FromAgent)null); | ||
546 | return; | ||
547 | case TaxationPackage.DEPENDENT__EXPENSE: | ||
548 | getExpense().clear(); | ||
549 | return; | ||
550 | } | ||
551 | super.eUnset(featureID); | ||
552 | } | ||
553 | |||
554 | /** | ||
555 | * <!-- begin-user-doc --> | ||
556 | * <!-- end-user-doc --> | ||
557 | * @generated | ||
558 | */ | ||
559 | @Override | ||
560 | public boolean eIsSet(int featureID) { | ||
561 | switch (featureID) { | ||
562 | case TaxationPackage.DEPENDENT__DEPENDENT_TYPE: | ||
563 | return dependent_type != DEPENDENT_TYPE_EDEFAULT; | ||
564 | case TaxationPackage.DEPENDENT__RESPONSIBLE_PERSON: | ||
565 | return getResponsible_person() != null; | ||
566 | case TaxationPackage.DEPENDENT__CONTINUED_STUDIES: | ||
567 | return continued_studies != CONTINUED_STUDIES_EDEFAULT; | ||
568 | case TaxationPackage.DEPENDENT__ALLOWANCES: | ||
569 | return allowances != null; | ||
570 | case TaxationPackage.DEPENDENT__HOUSEHOLD: | ||
571 | return getHousehold() != null; | ||
572 | case TaxationPackage.DEPENDENT__FROM_AGENT: | ||
573 | return from_agent != null; | ||
574 | case TaxationPackage.DEPENDENT__EXPENSE: | ||
575 | return expense != null && !expense.isEmpty(); | ||
576 | } | ||
577 | return super.eIsSet(featureID); | ||
578 | } | ||
579 | |||
580 | /** | ||
581 | * <!-- begin-user-doc --> | ||
582 | * <!-- end-user-doc --> | ||
583 | * @generated | ||
584 | */ | ||
585 | @Override | ||
586 | public String toString() { | ||
587 | if (eIsProxy()) return super.toString(); | ||
588 | |||
589 | StringBuilder result = new StringBuilder(super.toString()); | ||
590 | result.append(" (dependent_type: "); | ||
591 | result.append(dependent_type); | ||
592 | result.append(", continued_studies: "); | ||
593 | result.append(continued_studies); | ||
594 | result.append(')'); | ||
595 | return result.toString(); | ||
596 | } | ||
597 | |||
598 | } //DependentImpl | ||