aboutsummaryrefslogtreecommitdiffstats
path: root/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java
diff options
context:
space:
mode:
Diffstat (limited to 'Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java')
-rw-r--r--Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java243
1 files changed, 243 insertions, 0 deletions
diff --git a/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java
new file mode 100644
index 00000000..20151886
--- /dev/null
+++ b/Domains/Examples/ModelGenExampleFAM_plugin/ecore-gen/functionalarchitecture/impl/FunctionalInterfaceImpl.java
@@ -0,0 +1,243 @@
1/**
2 */
3package functionalarchitecture.impl;
4
5import functionalarchitecture.FunctionalData;
6import functionalarchitecture.FunctionalElement;
7import functionalarchitecture.FunctionalInterface;
8import functionalarchitecture.FunctionalarchitecturePackage;
9
10import java.util.Collection;
11
12import org.eclipse.emf.common.notify.Notification;
13import org.eclipse.emf.common.notify.NotificationChain;
14
15import org.eclipse.emf.common.util.EList;
16
17import org.eclipse.emf.ecore.EClass;
18import org.eclipse.emf.ecore.InternalEObject;
19
20import org.eclipse.emf.ecore.impl.ENotificationImpl;
21import org.eclipse.emf.ecore.impl.MinimalEObjectImpl;
22
23import org.eclipse.emf.ecore.util.EObjectContainmentWithInverseEList;
24import org.eclipse.emf.ecore.util.EcoreUtil;
25import org.eclipse.emf.ecore.util.InternalEList;
26
27/**
28 * <!-- begin-user-doc -->
29 * An implementation of the model object '<em><b>Functional Interface</b></em>'.
30 * <!-- end-user-doc -->
31 * <p>
32 * The following features are implemented:
33 * </p>
34 * <ul>
35 * <li>{@link functionalarchitecture.impl.FunctionalInterfaceImpl#getData <em>Data</em>}</li>
36 * <li>{@link functionalarchitecture.impl.FunctionalInterfaceImpl#getElement <em>Element</em>}</li>
37 * </ul>
38 *
39 * @generated
40 */
41public class FunctionalInterfaceImpl extends MinimalEObjectImpl.Container implements FunctionalInterface {
42 /**
43 * The cached value of the '{@link #getData() <em>Data</em>}' containment reference list.
44 * <!-- begin-user-doc -->
45 * <!-- end-user-doc -->
46 * @see #getData()
47 * @generated
48 * @ordered
49 */
50 protected EList<FunctionalData> data;
51
52 /**
53 * <!-- begin-user-doc -->
54 * <!-- end-user-doc -->
55 * @generated
56 */
57 protected FunctionalInterfaceImpl() {
58 super();
59 }
60
61 /**
62 * <!-- begin-user-doc -->
63 * <!-- end-user-doc -->
64 * @generated
65 */
66 @Override
67 protected EClass eStaticClass() {
68 return FunctionalarchitecturePackage.Literals.FUNCTIONAL_INTERFACE;
69 }
70
71 /**
72 * <!-- begin-user-doc -->
73 * <!-- end-user-doc -->
74 * @generated
75 */
76 public EList<FunctionalData> getData() {
77 if (data == null) {
78 data = new EObjectContainmentWithInverseEList<FunctionalData>(FunctionalData.class, this, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA, FunctionalarchitecturePackage.FUNCTIONAL_DATA__INTERFACE);
79 }
80 return data;
81 }
82
83 /**
84 * <!-- begin-user-doc -->
85 * <!-- end-user-doc -->
86 * @generated
87 */
88 public FunctionalElement getElement() {
89 if (eContainerFeatureID() != FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT) return null;
90 return (FunctionalElement)eInternalContainer();
91 }
92
93 /**
94 * <!-- begin-user-doc -->
95 * <!-- end-user-doc -->
96 * @generated
97 */
98 public NotificationChain basicSetElement(FunctionalElement newElement, NotificationChain msgs) {
99 msgs = eBasicSetContainer((InternalEObject)newElement, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT, msgs);
100 return msgs;
101 }
102
103 /**
104 * <!-- begin-user-doc -->
105 * <!-- end-user-doc -->
106 * @generated
107 */
108 public void setElement(FunctionalElement newElement) {
109 if (newElement != eInternalContainer() || (eContainerFeatureID() != FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT && newElement != null)) {
110 if (EcoreUtil.isAncestor(this, newElement))
111 throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
112 NotificationChain msgs = null;
113 if (eInternalContainer() != null)
114 msgs = eBasicRemoveFromContainer(msgs);
115 if (newElement != null)
116 msgs = ((InternalEObject)newElement).eInverseAdd(this, FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE, FunctionalElement.class, msgs);
117 msgs = basicSetElement(newElement, msgs);
118 if (msgs != null) msgs.dispatch();
119 }
120 else if (eNotificationRequired())
121 eNotify(new ENotificationImpl(this, Notification.SET, FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT, newElement, newElement));
122 }
123
124 /**
125 * <!-- begin-user-doc -->
126 * <!-- end-user-doc -->
127 * @generated
128 */
129 @SuppressWarnings("unchecked")
130 @Override
131 public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
132 switch (featureID) {
133 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA:
134 return ((InternalEList<InternalEObject>)(InternalEList<?>)getData()).basicAdd(otherEnd, msgs);
135 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
136 if (eInternalContainer() != null)
137 msgs = eBasicRemoveFromContainer(msgs);
138 return basicSetElement((FunctionalElement)otherEnd, msgs);
139 }
140 return super.eInverseAdd(otherEnd, featureID, msgs);
141 }
142
143 /**
144 * <!-- begin-user-doc -->
145 * <!-- end-user-doc -->
146 * @generated
147 */
148 @Override
149 public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
150 switch (featureID) {
151 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA:
152 return ((InternalEList<?>)getData()).basicRemove(otherEnd, msgs);
153 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
154 return basicSetElement(null, msgs);
155 }
156 return super.eInverseRemove(otherEnd, featureID, msgs);
157 }
158
159 /**
160 * <!-- begin-user-doc -->
161 * <!-- end-user-doc -->
162 * @generated
163 */
164 @Override
165 public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
166 switch (eContainerFeatureID()) {
167 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
168 return eInternalContainer().eInverseRemove(this, FunctionalarchitecturePackage.FUNCTIONAL_ELEMENT__INTERFACE, FunctionalElement.class, msgs);
169 }
170 return super.eBasicRemoveFromContainerFeature(msgs);
171 }
172
173 /**
174 * <!-- begin-user-doc -->
175 * <!-- end-user-doc -->
176 * @generated
177 */
178 @Override
179 public Object eGet(int featureID, boolean resolve, boolean coreType) {
180 switch (featureID) {
181 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA:
182 return getData();
183 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
184 return getElement();
185 }
186 return super.eGet(featureID, resolve, coreType);
187 }
188
189 /**
190 * <!-- begin-user-doc -->
191 * <!-- end-user-doc -->
192 * @generated
193 */
194 @SuppressWarnings("unchecked")
195 @Override
196 public void eSet(int featureID, Object newValue) {
197 switch (featureID) {
198 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA:
199 getData().clear();
200 getData().addAll((Collection<? extends FunctionalData>)newValue);
201 return;
202 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
203 setElement((FunctionalElement)newValue);
204 return;
205 }
206 super.eSet(featureID, newValue);
207 }
208
209 /**
210 * <!-- begin-user-doc -->
211 * <!-- end-user-doc -->
212 * @generated
213 */
214 @Override
215 public void eUnset(int featureID) {
216 switch (featureID) {
217 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA:
218 getData().clear();
219 return;
220 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
221 setElement((FunctionalElement)null);
222 return;
223 }
224 super.eUnset(featureID);
225 }
226
227 /**
228 * <!-- begin-user-doc -->
229 * <!-- end-user-doc -->
230 * @generated
231 */
232 @Override
233 public boolean eIsSet(int featureID) {
234 switch (featureID) {
235 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__DATA:
236 return data != null && !data.isEmpty();
237 case FunctionalarchitecturePackage.FUNCTIONAL_INTERFACE__ELEMENT:
238 return getElement() != null;
239 }
240 return super.eIsSet(featureID);
241 }
242
243} //FunctionalInterfaceImpl