aboutsummaryrefslogtreecommitdiffstats
path: root/Tests/MODELS2020-CaseStudies/models20.diversity-calculator/src/TaxationWithRoot/impl/ResourceImpl.java
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/MODELS2020-CaseStudies/models20.diversity-calculator/src/TaxationWithRoot/impl/ResourceImpl.java')
-rw-r--r--Tests/MODELS2020-CaseStudies/models20.diversity-calculator/src/TaxationWithRoot/impl/ResourceImpl.java153
1 files changed, 153 insertions, 0 deletions
diff --git a/Tests/MODELS2020-CaseStudies/models20.diversity-calculator/src/TaxationWithRoot/impl/ResourceImpl.java b/Tests/MODELS2020-CaseStudies/models20.diversity-calculator/src/TaxationWithRoot/impl/ResourceImpl.java
new file mode 100644
index 00000000..27e76c61
--- /dev/null
+++ b/Tests/MODELS2020-CaseStudies/models20.diversity-calculator/src/TaxationWithRoot/impl/ResourceImpl.java
@@ -0,0 +1,153 @@
1/**
2 */
3package TaxationWithRoot.impl;
4
5import TaxationWithRoot.Household;
6import TaxationWithRoot.Resource;
7import TaxationWithRoot.TaxationWithRootPackage;
8
9import java.util.Collection;
10
11import org.eclipse.emf.common.notify.NotificationChain;
12
13import org.eclipse.emf.common.util.EList;
14
15import org.eclipse.emf.ecore.EClass;
16import org.eclipse.emf.ecore.InternalEObject;
17
18import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
19
20import org.eclipse.emf.ecore.util.EObjectContainmentEList;
21import org.eclipse.emf.ecore.util.InternalEList;
22
23/**
24 * <!-- begin-user-doc -->
25 * An implementation of the model object '<em><b>Resource</b></em>'.
26 * <!-- end-user-doc -->
27 * <p>
28 * The following features are implemented:
29 * </p>
30 * <ul>
31 * <li>{@link TaxationWithRoot.impl.ResourceImpl#getContains <em>Contains</em>}</li>
32 * </ul>
33 *
34 * @generated
35 */
36public class ResourceImpl extends MinimalEObjectImpl.Container implements Resource {
37 /**
38 * The cached value of the '{@link #getContains() <em>Contains</em>}' containment reference list.
39 * <!-- begin-user-doc -->
40 * <!-- end-user-doc -->
41 * @see #getContains()
42 * @generated
43 * @ordered
44 */
45 protected EList<Household> contains;
46
47 /**
48 * <!-- begin-user-doc -->
49 * <!-- end-user-doc -->
50 * @generated
51 */
52 protected ResourceImpl() {
53 super();
54 }
55
56 /**
57 * <!-- begin-user-doc -->
58 * <!-- end-user-doc -->
59 * @generated
60 */
61 @Override
62 protected EClass eStaticClass() {
63 return TaxationWithRootPackage.Literals.RESOURCE;
64 }
65
66 /**
67 * <!-- begin-user-doc -->
68 * <!-- end-user-doc -->
69 * @generated
70 */
71 @Override
72 public EList<Household> getContains() {
73 if (contains == null) {
74 contains = new EObjectContainmentEList<Household>(Household.class, this, TaxationWithRootPackage.RESOURCE__CONTAINS);
75 }
76 return contains;
77 }
78
79 /**
80 * <!-- begin-user-doc -->
81 * <!-- end-user-doc -->
82 * @generated
83 */
84 @Override
85 public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
86 switch (featureID) {
87 case TaxationWithRootPackage.RESOURCE__CONTAINS:
88 return ((InternalEList<?>)getContains()).basicRemove(otherEnd, msgs);
89 }
90 return super.eInverseRemove(otherEnd, featureID, msgs);
91 }
92
93 /**
94 * <!-- begin-user-doc -->
95 * <!-- end-user-doc -->
96 * @generated
97 */
98 @Override
99 public Object eGet(int featureID, boolean resolve, boolean coreType) {
100 switch (featureID) {
101 case TaxationWithRootPackage.RESOURCE__CONTAINS:
102 return getContains();
103 }
104 return super.eGet(featureID, resolve, coreType);
105 }
106
107 /**
108 * <!-- begin-user-doc -->
109 * <!-- end-user-doc -->
110 * @generated
111 */
112 @SuppressWarnings("unchecked")
113 @Override
114 public void eSet(int featureID, Object newValue) {
115 switch (featureID) {
116 case TaxationWithRootPackage.RESOURCE__CONTAINS:
117 getContains().clear();
118 getContains().addAll((Collection<? extends Household>)newValue);
119 return;
120 }
121 super.eSet(featureID, newValue);
122 }
123
124 /**
125 * <!-- begin-user-doc -->
126 * <!-- end-user-doc -->
127 * @generated
128 */
129 @Override
130 public void eUnset(int featureID) {
131 switch (featureID) {
132 case TaxationWithRootPackage.RESOURCE__CONTAINS:
133 getContains().clear();
134 return;
135 }
136 super.eUnset(featureID);
137 }
138
139 /**
140 * <!-- begin-user-doc -->
141 * <!-- end-user-doc -->
142 * @generated
143 */
144 @Override
145 public boolean eIsSet(int featureID) {
146 switch (featureID) {
147 case TaxationWithRootPackage.RESOURCE__CONTAINS:
148 return contains != null && !contains.isEmpty();
149 }
150 return super.eIsSet(featureID);
151 }
152
153} //ResourceImpl