aboutsummaryrefslogtreecommitdiffstats
path: root/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/CommunicatingElementImpl.java
diff options
context:
space:
mode:
Diffstat (limited to 'Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/CommunicatingElementImpl.java')
-rw-r--r--Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/CommunicatingElementImpl.java237
1 files changed, 237 insertions, 0 deletions
diff --git a/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/CommunicatingElementImpl.java b/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/CommunicatingElementImpl.java
new file mode 100644
index 00000000..4b51e52e
--- /dev/null
+++ b/Domains/hu.bme.mit.inf.dslreasoner.domains.satellite/ecore-gen/hu/bme/mit/inf/dslreasoner/domains/satellite/impl/CommunicatingElementImpl.java
@@ -0,0 +1,237 @@
1/**
2 */
3package hu.bme.mit.inf.dslreasoner.domains.satellite.impl;
4
5import hu.bme.mit.inf.dslreasoner.domains.satellite.CommSubsystem;
6import hu.bme.mit.inf.dslreasoner.domains.satellite.CommunicatingElement;
7import hu.bme.mit.inf.dslreasoner.domains.satellite.DirectedCommunicationLink;
8import hu.bme.mit.inf.dslreasoner.domains.satellite.SatellitePackage;
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.EObjectContainmentEList;
24import org.eclipse.emf.ecore.util.InternalEList;
25
26/**
27 * <!-- begin-user-doc -->
28 * An implementation of the model object '<em><b>Communicating Element</b></em>'.
29 * <!-- end-user-doc -->
30 * <p>
31 * The following features are implemented:
32 * </p>
33 * <ul>
34 * <li>{@link hu.bme.mit.inf.dslreasoner.domains.satellite.impl.CommunicatingElementImpl#getCommSubsystem <em>Comm Subsystem</em>}</li>
35 * <li>{@link hu.bme.mit.inf.dslreasoner.domains.satellite.impl.CommunicatingElementImpl#getCommunicationLink <em>Communication Link</em>}</li>
36 * </ul>
37 *
38 * @generated
39 */
40public abstract class CommunicatingElementImpl extends MinimalEObjectImpl.Container implements CommunicatingElement {
41 /**
42 * The cached value of the '{@link #getCommSubsystem() <em>Comm Subsystem</em>}' containment reference list.
43 * <!-- begin-user-doc -->
44 * <!-- end-user-doc -->
45 * @see #getCommSubsystem()
46 * @generated
47 * @ordered
48 */
49 protected EList<CommSubsystem> commSubsystem;
50
51 /**
52 * The cached value of the '{@link #getCommunicationLink() <em>Communication Link</em>}' containment reference.
53 * <!-- begin-user-doc -->
54 * <!-- end-user-doc -->
55 * @see #getCommunicationLink()
56 * @generated
57 * @ordered
58 */
59 protected DirectedCommunicationLink communicationLink;
60
61 /**
62 * <!-- begin-user-doc -->
63 * <!-- end-user-doc -->
64 * @generated
65 */
66 protected CommunicatingElementImpl() {
67 super();
68 }
69
70 /**
71 * <!-- begin-user-doc -->
72 * <!-- end-user-doc -->
73 * @generated
74 */
75 @Override
76 protected EClass eStaticClass() {
77 return SatellitePackage.Literals.COMMUNICATING_ELEMENT;
78 }
79
80 /**
81 * <!-- begin-user-doc -->
82 * <!-- end-user-doc -->
83 * @generated
84 */
85 @Override
86 public EList<CommSubsystem> getCommSubsystem() {
87 if (commSubsystem == null) {
88 commSubsystem = new EObjectContainmentEList<CommSubsystem>(CommSubsystem.class, this,
89 SatellitePackage.COMMUNICATING_ELEMENT__COMM_SUBSYSTEM);
90 }
91 return commSubsystem;
92 }
93
94 /**
95 * <!-- begin-user-doc -->
96 * <!-- end-user-doc -->
97 * @generated
98 */
99 @Override
100 public DirectedCommunicationLink getCommunicationLink() {
101 return communicationLink;
102 }
103
104 /**
105 * <!-- begin-user-doc -->
106 * <!-- end-user-doc -->
107 * @generated
108 */
109 public NotificationChain basicSetCommunicationLink(DirectedCommunicationLink newCommunicationLink,
110 NotificationChain msgs) {
111 DirectedCommunicationLink oldCommunicationLink = communicationLink;
112 communicationLink = newCommunicationLink;
113 if (eNotificationRequired()) {
114 ENotificationImpl notification = new ENotificationImpl(this, Notification.SET,
115 SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK, oldCommunicationLink,
116 newCommunicationLink);
117 if (msgs == null)
118 msgs = notification;
119 else
120 msgs.add(notification);
121 }
122 return msgs;
123 }
124
125 /**
126 * <!-- begin-user-doc -->
127 * <!-- end-user-doc -->
128 * @generated
129 */
130 @Override
131 public void setCommunicationLink(DirectedCommunicationLink newCommunicationLink) {
132 if (newCommunicationLink != communicationLink) {
133 NotificationChain msgs = null;
134 if (communicationLink != null)
135 msgs = ((InternalEObject) communicationLink).eInverseRemove(this,
136 EOPPOSITE_FEATURE_BASE - SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK, null,
137 msgs);
138 if (newCommunicationLink != null)
139 msgs = ((InternalEObject) newCommunicationLink).eInverseAdd(this,
140 EOPPOSITE_FEATURE_BASE - SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK, null,
141 msgs);
142 msgs = basicSetCommunicationLink(newCommunicationLink, msgs);
143 if (msgs != null)
144 msgs.dispatch();
145 } else if (eNotificationRequired())
146 eNotify(new ENotificationImpl(this, Notification.SET,
147 SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK, newCommunicationLink,
148 newCommunicationLink));
149 }
150
151 /**
152 * <!-- begin-user-doc -->
153 * <!-- end-user-doc -->
154 * @generated
155 */
156 @Override
157 public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
158 switch (featureID) {
159 case SatellitePackage.COMMUNICATING_ELEMENT__COMM_SUBSYSTEM:
160 return ((InternalEList<?>) getCommSubsystem()).basicRemove(otherEnd, msgs);
161 case SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK:
162 return basicSetCommunicationLink(null, msgs);
163 }
164 return super.eInverseRemove(otherEnd, featureID, msgs);
165 }
166
167 /**
168 * <!-- begin-user-doc -->
169 * <!-- end-user-doc -->
170 * @generated
171 */
172 @Override
173 public Object eGet(int featureID, boolean resolve, boolean coreType) {
174 switch (featureID) {
175 case SatellitePackage.COMMUNICATING_ELEMENT__COMM_SUBSYSTEM:
176 return getCommSubsystem();
177 case SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK:
178 return getCommunicationLink();
179 }
180 return super.eGet(featureID, resolve, coreType);
181 }
182
183 /**
184 * <!-- begin-user-doc -->
185 * <!-- end-user-doc -->
186 * @generated
187 */
188 @SuppressWarnings("unchecked")
189 @Override
190 public void eSet(int featureID, Object newValue) {
191 switch (featureID) {
192 case SatellitePackage.COMMUNICATING_ELEMENT__COMM_SUBSYSTEM:
193 getCommSubsystem().clear();
194 getCommSubsystem().addAll((Collection<? extends CommSubsystem>) newValue);
195 return;
196 case SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK:
197 setCommunicationLink((DirectedCommunicationLink) newValue);
198 return;
199 }
200 super.eSet(featureID, newValue);
201 }
202
203 /**
204 * <!-- begin-user-doc -->
205 * <!-- end-user-doc -->
206 * @generated
207 */
208 @Override
209 public void eUnset(int featureID) {
210 switch (featureID) {
211 case SatellitePackage.COMMUNICATING_ELEMENT__COMM_SUBSYSTEM:
212 getCommSubsystem().clear();
213 return;
214 case SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK:
215 setCommunicationLink((DirectedCommunicationLink) null);
216 return;
217 }
218 super.eUnset(featureID);
219 }
220
221 /**
222 * <!-- begin-user-doc -->
223 * <!-- end-user-doc -->
224 * @generated
225 */
226 @Override
227 public boolean eIsSet(int featureID) {
228 switch (featureID) {
229 case SatellitePackage.COMMUNICATING_ELEMENT__COMM_SUBSYSTEM:
230 return commSubsystem != null && !commSubsystem.isEmpty();
231 case SatellitePackage.COMMUNICATING_ELEMENT__COMMUNICATION_LINK:
232 return communicationLink != null;
233 }
234 return super.eIsSet(featureID);
235 }
236
237} //CommunicatingElementImpl