diff options
author | Aren Babikian <aren.babikian@mail.mcgill.ca> | 2021-01-14 10:34:59 -0500 |
---|---|---|
committer | Aren Babikian <aren.babikian@mail.mcgill.ca> | 2021-01-14 10:34:59 -0500 |
commit | dc931c24870432efcd3c3fca4fb6fbd401c70420 (patch) | |
tree | 60e417e047ac712be38058a5b358d5ea2f24c3fe /Domains/crossingScenario/ecore-gen/crossingScenario/util/CrossingScenarioSwitch.java | |
parent | deactivate the constraints used for debugging (diff) | |
download | VIATRA-Generator-dc931c24870432efcd3c3fca4fb6fbd401c70420.tar.gz VIATRA-Generator-dc931c24870432efcd3c3fca4fb6fbd401c70420.tar.zst VIATRA-Generator-dc931c24870432efcd3c3fca4fb6fbd401c70420.zip |
refactor simpleScenario->crossingScenario
Diffstat (limited to 'Domains/crossingScenario/ecore-gen/crossingScenario/util/CrossingScenarioSwitch.java')
-rw-r--r-- | Domains/crossingScenario/ecore-gen/crossingScenario/util/CrossingScenarioSwitch.java | 353 |
1 files changed, 353 insertions, 0 deletions
diff --git a/Domains/crossingScenario/ecore-gen/crossingScenario/util/CrossingScenarioSwitch.java b/Domains/crossingScenario/ecore-gen/crossingScenario/util/CrossingScenarioSwitch.java new file mode 100644 index 00000000..b14a5c24 --- /dev/null +++ b/Domains/crossingScenario/ecore-gen/crossingScenario/util/CrossingScenarioSwitch.java | |||
@@ -0,0 +1,353 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package crossingScenario.util; | ||
4 | |||
5 | import crossingScenario.*; | ||
6 | |||
7 | import org.eclipse.emf.ecore.EObject; | ||
8 | import org.eclipse.emf.ecore.EPackage; | ||
9 | |||
10 | import org.eclipse.emf.ecore.util.Switch; | ||
11 | |||
12 | /** | ||
13 | * <!-- begin-user-doc --> | ||
14 | * The <b>Switch</b> for the model's inheritance hierarchy. | ||
15 | * It supports the call {@link #doSwitch(EObject) doSwitch(object)} | ||
16 | * to invoke the <code>caseXXX</code> method for each class of the model, | ||
17 | * starting with the actual class of the object | ||
18 | * and proceeding up the inheritance hierarchy | ||
19 | * until a non-null result is returned, | ||
20 | * which is the result of the switch. | ||
21 | * <!-- end-user-doc --> | ||
22 | * @see crossingScenario.CrossingScenarioPackage | ||
23 | * @generated | ||
24 | */ | ||
25 | public class CrossingScenarioSwitch<T> extends Switch<T> { | ||
26 | /** | ||
27 | * The cached model package | ||
28 | * <!-- begin-user-doc --> | ||
29 | * <!-- end-user-doc --> | ||
30 | * @generated | ||
31 | */ | ||
32 | protected static CrossingScenarioPackage modelPackage; | ||
33 | |||
34 | /** | ||
35 | * Creates an instance of the switch. | ||
36 | * <!-- begin-user-doc --> | ||
37 | * <!-- end-user-doc --> | ||
38 | * @generated | ||
39 | */ | ||
40 | public CrossingScenarioSwitch() { | ||
41 | if (modelPackage == null) { | ||
42 | modelPackage = CrossingScenarioPackage.eINSTANCE; | ||
43 | } | ||
44 | } | ||
45 | |||
46 | /** | ||
47 | * Checks whether this is a switch for the given package. | ||
48 | * <!-- begin-user-doc --> | ||
49 | * <!-- end-user-doc --> | ||
50 | * @param ePackage the package in question. | ||
51 | * @return whether this is a switch for the given package. | ||
52 | * @generated | ||
53 | */ | ||
54 | @Override | ||
55 | protected boolean isSwitchFor(EPackage ePackage) { | ||
56 | return ePackage == modelPackage; | ||
57 | } | ||
58 | |||
59 | /** | ||
60 | * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result. | ||
61 | * <!-- begin-user-doc --> | ||
62 | * <!-- end-user-doc --> | ||
63 | * @return the first non-null result returned by a <code>caseXXX</code> call. | ||
64 | * @generated | ||
65 | */ | ||
66 | @Override | ||
67 | protected T doSwitch(int classifierID, EObject theEObject) { | ||
68 | switch (classifierID) { | ||
69 | case CrossingScenarioPackage.CROSSING_SCENARIO: { | ||
70 | CrossingScenario crossingScenario = (CrossingScenario)theEObject; | ||
71 | T result = caseCrossingScenario(crossingScenario); | ||
72 | if (result == null) result = defaultCase(theEObject); | ||
73 | return result; | ||
74 | } | ||
75 | case CrossingScenarioPackage.LANE: { | ||
76 | Lane lane = (Lane)theEObject; | ||
77 | T result = caseLane(lane); | ||
78 | if (result == null) result = defaultCase(theEObject); | ||
79 | return result; | ||
80 | } | ||
81 | case CrossingScenarioPackage.ACTOR: { | ||
82 | Actor actor = (Actor)theEObject; | ||
83 | T result = caseActor(actor); | ||
84 | if (result == null) result = defaultCase(theEObject); | ||
85 | return result; | ||
86 | } | ||
87 | case CrossingScenarioPackage.RELATION: { | ||
88 | Relation relation = (Relation)theEObject; | ||
89 | T result = caseRelation(relation); | ||
90 | if (result == null) result = defaultCase(theEObject); | ||
91 | return result; | ||
92 | } | ||
93 | case CrossingScenarioPackage.SPATIAL_RELATION: { | ||
94 | SpatialRelation spatialRelation = (SpatialRelation)theEObject; | ||
95 | T result = caseSpatialRelation(spatialRelation); | ||
96 | if (result == null) result = caseRelation(spatialRelation); | ||
97 | if (result == null) result = defaultCase(theEObject); | ||
98 | return result; | ||
99 | } | ||
100 | case CrossingScenarioPackage.TEMPORAL_RELATION: { | ||
101 | TemporalRelation temporalRelation = (TemporalRelation)theEObject; | ||
102 | T result = caseTemporalRelation(temporalRelation); | ||
103 | if (result == null) result = caseRelation(temporalRelation); | ||
104 | if (result == null) result = defaultCase(theEObject); | ||
105 | return result; | ||
106 | } | ||
107 | case CrossingScenarioPackage.VISION_BLOCKED: { | ||
108 | VisionBlocked visionBlocked = (VisionBlocked)theEObject; | ||
109 | T result = caseVisionBlocked(visionBlocked); | ||
110 | if (result == null) result = caseSpatialRelation(visionBlocked); | ||
111 | if (result == null) result = caseRelation(visionBlocked); | ||
112 | if (result == null) result = defaultCase(theEObject); | ||
113 | return result; | ||
114 | } | ||
115 | case CrossingScenarioPackage.SEPARATION_DISTANCE: { | ||
116 | SeparationDistance separationDistance = (SeparationDistance)theEObject; | ||
117 | T result = caseSeparationDistance(separationDistance); | ||
118 | if (result == null) result = caseSpatialRelation(separationDistance); | ||
119 | if (result == null) result = caseRelation(separationDistance); | ||
120 | if (result == null) result = defaultCase(theEObject); | ||
121 | return result; | ||
122 | } | ||
123 | case CrossingScenarioPackage.COLLISION_EXISTS: { | ||
124 | CollisionExists collisionExists = (CollisionExists)theEObject; | ||
125 | T result = caseCollisionExists(collisionExists); | ||
126 | if (result == null) result = caseTemporalRelation(collisionExists); | ||
127 | if (result == null) result = caseRelation(collisionExists); | ||
128 | if (result == null) result = defaultCase(theEObject); | ||
129 | return result; | ||
130 | } | ||
131 | case CrossingScenarioPackage.COLLISION_DOES_NOT_EXIST: { | ||
132 | CollisionDoesNotExist collisionDoesNotExist = (CollisionDoesNotExist)theEObject; | ||
133 | T result = caseCollisionDoesNotExist(collisionDoesNotExist); | ||
134 | if (result == null) result = caseTemporalRelation(collisionDoesNotExist); | ||
135 | if (result == null) result = caseRelation(collisionDoesNotExist); | ||
136 | if (result == null) result = defaultCase(theEObject); | ||
137 | return result; | ||
138 | } | ||
139 | case CrossingScenarioPackage.PEDESTRIAN: { | ||
140 | Pedestrian pedestrian = (Pedestrian)theEObject; | ||
141 | T result = casePedestrian(pedestrian); | ||
142 | if (result == null) result = caseActor(pedestrian); | ||
143 | if (result == null) result = defaultCase(theEObject); | ||
144 | return result; | ||
145 | } | ||
146 | case CrossingScenarioPackage.VEHICLE: { | ||
147 | Vehicle vehicle = (Vehicle)theEObject; | ||
148 | T result = caseVehicle(vehicle); | ||
149 | if (result == null) result = caseActor(vehicle); | ||
150 | if (result == null) result = defaultCase(theEObject); | ||
151 | return result; | ||
152 | } | ||
153 | default: return defaultCase(theEObject); | ||
154 | } | ||
155 | } | ||
156 | |||
157 | /** | ||
158 | * Returns the result of interpreting the object as an instance of '<em>Crossing Scenario</em>'. | ||
159 | * <!-- begin-user-doc --> | ||
160 | * This implementation returns null; | ||
161 | * returning a non-null result will terminate the switch. | ||
162 | * <!-- end-user-doc --> | ||
163 | * @param object the target of the switch. | ||
164 | * @return the result of interpreting the object as an instance of '<em>Crossing Scenario</em>'. | ||
165 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
166 | * @generated | ||
167 | */ | ||
168 | public T caseCrossingScenario(CrossingScenario object) { | ||
169 | return null; | ||
170 | } | ||
171 | |||
172 | /** | ||
173 | * Returns the result of interpreting the object as an instance of '<em>Lane</em>'. | ||
174 | * <!-- begin-user-doc --> | ||
175 | * This implementation returns null; | ||
176 | * returning a non-null result will terminate the switch. | ||
177 | * <!-- end-user-doc --> | ||
178 | * @param object the target of the switch. | ||
179 | * @return the result of interpreting the object as an instance of '<em>Lane</em>'. | ||
180 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
181 | * @generated | ||
182 | */ | ||
183 | public T caseLane(Lane object) { | ||
184 | return null; | ||
185 | } | ||
186 | |||
187 | /** | ||
188 | * Returns the result of interpreting the object as an instance of '<em>Actor</em>'. | ||
189 | * <!-- begin-user-doc --> | ||
190 | * This implementation returns null; | ||
191 | * returning a non-null result will terminate the switch. | ||
192 | * <!-- end-user-doc --> | ||
193 | * @param object the target of the switch. | ||
194 | * @return the result of interpreting the object as an instance of '<em>Actor</em>'. | ||
195 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
196 | * @generated | ||
197 | */ | ||
198 | public T caseActor(Actor object) { | ||
199 | return null; | ||
200 | } | ||
201 | |||
202 | /** | ||
203 | * Returns the result of interpreting the object as an instance of '<em>Relation</em>'. | ||
204 | * <!-- begin-user-doc --> | ||
205 | * This implementation returns null; | ||
206 | * returning a non-null result will terminate the switch. | ||
207 | * <!-- end-user-doc --> | ||
208 | * @param object the target of the switch. | ||
209 | * @return the result of interpreting the object as an instance of '<em>Relation</em>'. | ||
210 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
211 | * @generated | ||
212 | */ | ||
213 | public T caseRelation(Relation object) { | ||
214 | return null; | ||
215 | } | ||
216 | |||
217 | /** | ||
218 | * Returns the result of interpreting the object as an instance of '<em>Spatial Relation</em>'. | ||
219 | * <!-- begin-user-doc --> | ||
220 | * This implementation returns null; | ||
221 | * returning a non-null result will terminate the switch. | ||
222 | * <!-- end-user-doc --> | ||
223 | * @param object the target of the switch. | ||
224 | * @return the result of interpreting the object as an instance of '<em>Spatial Relation</em>'. | ||
225 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
226 | * @generated | ||
227 | */ | ||
228 | public T caseSpatialRelation(SpatialRelation object) { | ||
229 | return null; | ||
230 | } | ||
231 | |||
232 | /** | ||
233 | * Returns the result of interpreting the object as an instance of '<em>Temporal Relation</em>'. | ||
234 | * <!-- begin-user-doc --> | ||
235 | * This implementation returns null; | ||
236 | * returning a non-null result will terminate the switch. | ||
237 | * <!-- end-user-doc --> | ||
238 | * @param object the target of the switch. | ||
239 | * @return the result of interpreting the object as an instance of '<em>Temporal Relation</em>'. | ||
240 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
241 | * @generated | ||
242 | */ | ||
243 | public T caseTemporalRelation(TemporalRelation object) { | ||
244 | return null; | ||
245 | } | ||
246 | |||
247 | /** | ||
248 | * Returns the result of interpreting the object as an instance of '<em>Vision Blocked</em>'. | ||
249 | * <!-- begin-user-doc --> | ||
250 | * This implementation returns null; | ||
251 | * returning a non-null result will terminate the switch. | ||
252 | * <!-- end-user-doc --> | ||
253 | * @param object the target of the switch. | ||
254 | * @return the result of interpreting the object as an instance of '<em>Vision Blocked</em>'. | ||
255 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
256 | * @generated | ||
257 | */ | ||
258 | public T caseVisionBlocked(VisionBlocked object) { | ||
259 | return null; | ||
260 | } | ||
261 | |||
262 | /** | ||
263 | * Returns the result of interpreting the object as an instance of '<em>Separation Distance</em>'. | ||
264 | * <!-- begin-user-doc --> | ||
265 | * This implementation returns null; | ||
266 | * returning a non-null result will terminate the switch. | ||
267 | * <!-- end-user-doc --> | ||
268 | * @param object the target of the switch. | ||
269 | * @return the result of interpreting the object as an instance of '<em>Separation Distance</em>'. | ||
270 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
271 | * @generated | ||
272 | */ | ||
273 | public T caseSeparationDistance(SeparationDistance object) { | ||
274 | return null; | ||
275 | } | ||
276 | |||
277 | /** | ||
278 | * Returns the result of interpreting the object as an instance of '<em>Collision Exists</em>'. | ||
279 | * <!-- begin-user-doc --> | ||
280 | * This implementation returns null; | ||
281 | * returning a non-null result will terminate the switch. | ||
282 | * <!-- end-user-doc --> | ||
283 | * @param object the target of the switch. | ||
284 | * @return the result of interpreting the object as an instance of '<em>Collision Exists</em>'. | ||
285 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
286 | * @generated | ||
287 | */ | ||
288 | public T caseCollisionExists(CollisionExists object) { | ||
289 | return null; | ||
290 | } | ||
291 | |||
292 | /** | ||
293 | * Returns the result of interpreting the object as an instance of '<em>Collision Does Not Exist</em>'. | ||
294 | * <!-- begin-user-doc --> | ||
295 | * This implementation returns null; | ||
296 | * returning a non-null result will terminate the switch. | ||
297 | * <!-- end-user-doc --> | ||
298 | * @param object the target of the switch. | ||
299 | * @return the result of interpreting the object as an instance of '<em>Collision Does Not Exist</em>'. | ||
300 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
301 | * @generated | ||
302 | */ | ||
303 | public T caseCollisionDoesNotExist(CollisionDoesNotExist object) { | ||
304 | return null; | ||
305 | } | ||
306 | |||
307 | /** | ||
308 | * Returns the result of interpreting the object as an instance of '<em>Pedestrian</em>'. | ||
309 | * <!-- begin-user-doc --> | ||
310 | * This implementation returns null; | ||
311 | * returning a non-null result will terminate the switch. | ||
312 | * <!-- end-user-doc --> | ||
313 | * @param object the target of the switch. | ||
314 | * @return the result of interpreting the object as an instance of '<em>Pedestrian</em>'. | ||
315 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
316 | * @generated | ||
317 | */ | ||
318 | public T casePedestrian(Pedestrian object) { | ||
319 | return null; | ||
320 | } | ||
321 | |||
322 | /** | ||
323 | * Returns the result of interpreting the object as an instance of '<em>Vehicle</em>'. | ||
324 | * <!-- begin-user-doc --> | ||
325 | * This implementation returns null; | ||
326 | * returning a non-null result will terminate the switch. | ||
327 | * <!-- end-user-doc --> | ||
328 | * @param object the target of the switch. | ||
329 | * @return the result of interpreting the object as an instance of '<em>Vehicle</em>'. | ||
330 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject) | ||
331 | * @generated | ||
332 | */ | ||
333 | public T caseVehicle(Vehicle object) { | ||
334 | return null; | ||
335 | } | ||
336 | |||
337 | /** | ||
338 | * Returns the result of interpreting the object as an instance of '<em>EObject</em>'. | ||
339 | * <!-- begin-user-doc --> | ||
340 | * This implementation returns null; | ||
341 | * returning a non-null result will terminate the switch, but this is the last case anyway. | ||
342 | * <!-- end-user-doc --> | ||
343 | * @param object the target of the switch. | ||
344 | * @return the result of interpreting the object as an instance of '<em>EObject</em>'. | ||
345 | * @see #doSwitch(org.eclipse.emf.ecore.EObject) | ||
346 | * @generated | ||
347 | */ | ||
348 | @Override | ||
349 | public T defaultCase(EObject object) { | ||
350 | return null; | ||
351 | } | ||
352 | |||
353 | } //CrossingScenarioSwitch | ||