diff options
author | 2020-05-19 21:18:06 +0200 | |
---|---|---|
committer | 2020-05-19 21:18:06 +0200 | |
commit | b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b (patch) | |
tree | ad3222182065b8fac7d9b3d528c4efabf2aa0dd2 /Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/ExternMetricDefinitionImpl.java | |
parent | Merge branch 'master' of github.com:viatra/VIATRA-Generator (diff) | |
download | VIATRA-Generator-b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b.tar.gz VIATRA-Generator-b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b.tar.zst VIATRA-Generator-b3c1c5b30ae8ea7ebad391c9250b4509d5a4cc9b.zip |
Config language WIP
Diffstat (limited to 'Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/ExternMetricDefinitionImpl.java')
-rw-r--r-- | Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/ExternMetricDefinitionImpl.java | 270 |
1 files changed, 0 insertions, 270 deletions
diff --git a/Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/ExternMetricDefinitionImpl.java b/Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/ExternMetricDefinitionImpl.java deleted file mode 100644 index e324c38a..00000000 --- a/Application/org.eclipse.viatra.solver.language/src-gen/org/eclipse/viatra/solver/language/solverLanguage/impl/ExternMetricDefinitionImpl.java +++ /dev/null | |||
@@ -1,270 +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.Call; | ||
15 | import org.eclipse.viatra.solver.language.solverLanguage.ExternMetricDefinition; | ||
16 | import org.eclipse.viatra.solver.language.solverLanguage.MetricType; | ||
17 | import org.eclipse.viatra.solver.language.solverLanguage.SolverLanguagePackage; | ||
18 | |||
19 | /** | ||
20 | * <!-- begin-user-doc --> | ||
21 | * An implementation of the model object '<em><b>Extern Metric Definition</b></em>'. | ||
22 | * <!-- end-user-doc --> | ||
23 | * <p> | ||
24 | * The following features are implemented: | ||
25 | * </p> | ||
26 | * <ul> | ||
27 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.ExternMetricDefinitionImpl#getType <em>Type</em>}</li> | ||
28 | * <li>{@link org.eclipse.viatra.solver.language.solverLanguage.impl.ExternMetricDefinitionImpl#getHead <em>Head</em>}</li> | ||
29 | * </ul> | ||
30 | * | ||
31 | * @generated | ||
32 | */ | ||
33 | public class ExternMetricDefinitionImpl extends StatementImpl implements ExternMetricDefinition | ||
34 | { | ||
35 | /** | ||
36 | * The default value of the '{@link #getType() <em>Type</em>}' attribute. | ||
37 | * <!-- begin-user-doc --> | ||
38 | * <!-- end-user-doc --> | ||
39 | * @see #getType() | ||
40 | * @generated | ||
41 | * @ordered | ||
42 | */ | ||
43 | protected static final MetricType TYPE_EDEFAULT = MetricType.INT; | ||
44 | |||
45 | /** | ||
46 | * The cached value of the '{@link #getType() <em>Type</em>}' attribute. | ||
47 | * <!-- begin-user-doc --> | ||
48 | * <!-- end-user-doc --> | ||
49 | * @see #getType() | ||
50 | * @generated | ||
51 | * @ordered | ||
52 | */ | ||
53 | protected MetricType type = TYPE_EDEFAULT; | ||
54 | |||
55 | /** | ||
56 | * The cached value of the '{@link #getHead() <em>Head</em>}' containment reference. | ||
57 | * <!-- begin-user-doc --> | ||
58 | * <!-- end-user-doc --> | ||
59 | * @see #getHead() | ||
60 | * @generated | ||
61 | * @ordered | ||
62 | */ | ||
63 | protected Call head; | ||
64 | |||
65 | /** | ||
66 | * <!-- begin-user-doc --> | ||
67 | * <!-- end-user-doc --> | ||
68 | * @generated | ||
69 | */ | ||
70 | protected ExternMetricDefinitionImpl() | ||
71 | { | ||
72 | super(); | ||
73 | } | ||
74 | |||
75 | /** | ||
76 | * <!-- begin-user-doc --> | ||
77 | * <!-- end-user-doc --> | ||
78 | * @generated | ||
79 | */ | ||
80 | @Override | ||
81 | protected EClass eStaticClass() | ||
82 | { | ||
83 | return SolverLanguagePackage.Literals.EXTERN_METRIC_DEFINITION; | ||
84 | } | ||
85 | |||
86 | /** | ||
87 | * <!-- begin-user-doc --> | ||
88 | * <!-- end-user-doc --> | ||
89 | * @generated | ||
90 | */ | ||
91 | @Override | ||
92 | public MetricType getType() | ||
93 | { | ||
94 | return type; | ||
95 | } | ||
96 | |||
97 | /** | ||
98 | * <!-- begin-user-doc --> | ||
99 | * <!-- end-user-doc --> | ||
100 | * @generated | ||
101 | */ | ||
102 | @Override | ||
103 | public void setType(MetricType newType) | ||
104 | { | ||
105 | MetricType oldType = type; | ||
106 | type = newType == null ? TYPE_EDEFAULT : newType; | ||
107 | if (eNotificationRequired()) | ||
108 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.EXTERN_METRIC_DEFINITION__TYPE, oldType, type)); | ||
109 | } | ||
110 | |||
111 | /** | ||
112 | * <!-- begin-user-doc --> | ||
113 | * <!-- end-user-doc --> | ||
114 | * @generated | ||
115 | */ | ||
116 | @Override | ||
117 | public Call getHead() | ||
118 | { | ||
119 | return head; | ||
120 | } | ||
121 | |||
122 | /** | ||
123 | * <!-- begin-user-doc --> | ||
124 | * <!-- end-user-doc --> | ||
125 | * @generated | ||
126 | */ | ||
127 | public NotificationChain basicSetHead(Call newHead, NotificationChain msgs) | ||
128 | { | ||
129 | Call oldHead = head; | ||
130 | head = newHead; | ||
131 | if (eNotificationRequired()) | ||
132 | { | ||
133 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD, oldHead, newHead); | ||
134 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
135 | } | ||
136 | return msgs; | ||
137 | } | ||
138 | |||
139 | /** | ||
140 | * <!-- begin-user-doc --> | ||
141 | * <!-- end-user-doc --> | ||
142 | * @generated | ||
143 | */ | ||
144 | @Override | ||
145 | public void setHead(Call newHead) | ||
146 | { | ||
147 | if (newHead != head) | ||
148 | { | ||
149 | NotificationChain msgs = null; | ||
150 | if (head != null) | ||
151 | msgs = ((InternalEObject)head).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD, null, msgs); | ||
152 | if (newHead != null) | ||
153 | msgs = ((InternalEObject)newHead).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD, null, msgs); | ||
154 | msgs = basicSetHead(newHead, msgs); | ||
155 | if (msgs != null) msgs.dispatch(); | ||
156 | } | ||
157 | else if (eNotificationRequired()) | ||
158 | eNotify(new ENotificationImpl(this, Notification.SET, SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD, newHead, newHead)); | ||
159 | } | ||
160 | |||
161 | /** | ||
162 | * <!-- begin-user-doc --> | ||
163 | * <!-- end-user-doc --> | ||
164 | * @generated | ||
165 | */ | ||
166 | @Override | ||
167 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) | ||
168 | { | ||
169 | switch (featureID) | ||
170 | { | ||
171 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD: | ||
172 | return basicSetHead(null, msgs); | ||
173 | } | ||
174 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
175 | } | ||
176 | |||
177 | /** | ||
178 | * <!-- begin-user-doc --> | ||
179 | * <!-- end-user-doc --> | ||
180 | * @generated | ||
181 | */ | ||
182 | @Override | ||
183 | public Object eGet(int featureID, boolean resolve, boolean coreType) | ||
184 | { | ||
185 | switch (featureID) | ||
186 | { | ||
187 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__TYPE: | ||
188 | return getType(); | ||
189 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD: | ||
190 | return getHead(); | ||
191 | } | ||
192 | return super.eGet(featureID, resolve, coreType); | ||
193 | } | ||
194 | |||
195 | /** | ||
196 | * <!-- begin-user-doc --> | ||
197 | * <!-- end-user-doc --> | ||
198 | * @generated | ||
199 | */ | ||
200 | @Override | ||
201 | public void eSet(int featureID, Object newValue) | ||
202 | { | ||
203 | switch (featureID) | ||
204 | { | ||
205 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__TYPE: | ||
206 | setType((MetricType)newValue); | ||
207 | return; | ||
208 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD: | ||
209 | setHead((Call)newValue); | ||
210 | return; | ||
211 | } | ||
212 | super.eSet(featureID, newValue); | ||
213 | } | ||
214 | |||
215 | /** | ||
216 | * <!-- begin-user-doc --> | ||
217 | * <!-- end-user-doc --> | ||
218 | * @generated | ||
219 | */ | ||
220 | @Override | ||
221 | public void eUnset(int featureID) | ||
222 | { | ||
223 | switch (featureID) | ||
224 | { | ||
225 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__TYPE: | ||
226 | setType(TYPE_EDEFAULT); | ||
227 | return; | ||
228 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD: | ||
229 | setHead((Call)null); | ||
230 | return; | ||
231 | } | ||
232 | super.eUnset(featureID); | ||
233 | } | ||
234 | |||
235 | /** | ||
236 | * <!-- begin-user-doc --> | ||
237 | * <!-- end-user-doc --> | ||
238 | * @generated | ||
239 | */ | ||
240 | @Override | ||
241 | public boolean eIsSet(int featureID) | ||
242 | { | ||
243 | switch (featureID) | ||
244 | { | ||
245 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__TYPE: | ||
246 | return type != TYPE_EDEFAULT; | ||
247 | case SolverLanguagePackage.EXTERN_METRIC_DEFINITION__HEAD: | ||
248 | return head != null; | ||
249 | } | ||
250 | return super.eIsSet(featureID); | ||
251 | } | ||
252 | |||
253 | /** | ||
254 | * <!-- begin-user-doc --> | ||
255 | * <!-- end-user-doc --> | ||
256 | * @generated | ||
257 | */ | ||
258 | @Override | ||
259 | public String toString() | ||
260 | { | ||
261 | if (eIsProxy()) return super.toString(); | ||
262 | |||
263 | StringBuilder result = new StringBuilder(super.toString()); | ||
264 | result.append(" (type: "); | ||
265 | result.append(type); | ||
266 | result.append(')'); | ||
267 | return result.toString(); | ||
268 | } | ||
269 | |||
270 | } //ExternMetricDefinitionImpl | ||