Regenerates EMF Compare static test profile.
[EMFCompare2.git] / plugins / org.eclipse.emf.compare.uml2.tests / profile / org / eclipse / emf / compare / uml2 / profile / test / uml2comparetestprofile / util / UML2CompareTestProfileSwitch.java
blobdaf10ba5b91087593412294aff2c0e09d4051137
1 /*******************************************************************************
2 * Copyright (c) 2011, 2014 Obeo.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Eclipse Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/epl-v10.html
7 *
8 * Contributors:
9 * Obeo - initial API and implementation
10 *******************************************************************************/
11 package org.eclipse.emf.compare.uml2.profile.test.uml2comparetestprofile.util;
13 import org.eclipse.emf.compare.uml2.profile.test.uml2comparetestprofile.ACliche;
14 import org.eclipse.emf.compare.uml2.profile.test.uml2comparetestprofile.ACliche2;
15 import org.eclipse.emf.compare.uml2.profile.test.uml2comparetestprofile.ACliche3;
16 import org.eclipse.emf.compare.uml2.profile.test.uml2comparetestprofile.UML2CompareTestProfilePackage;
17 import org.eclipse.emf.ecore.EObject;
18 import org.eclipse.emf.ecore.EPackage;
19 import org.eclipse.emf.ecore.util.Switch;
21 /**
22 * <!-- begin-user-doc --> The <b>Switch</b> for the model's inheritance hierarchy. It supports the call
23 * {@link #doSwitch(EObject) doSwitch(object)} to invoke the <code>caseXXX</code> method for each class of the
24 * model, starting with the actual class of the object and proceeding up the inheritance hierarchy until a
25 * non-null result is returned, which is the result of the switch. <!-- end-user-doc -->
26 * @see org.eclipse.emf.compare.uml2.profile.test.uml2comparetestprofile.UML2CompareTestProfilePackage
27 * @generated
29 public class UML2CompareTestProfileSwitch<T> extends Switch<T> {
30 /**
31 * The cached model package
32 * <!-- begin-user-doc --> <!-- end-user-doc -->
33 * @generated
35 protected static UML2CompareTestProfilePackage modelPackage;
37 /**
38 * Creates an instance of the switch.
39 * <!-- begin-user-doc --> <!-- end-user-doc -->
40 * @generated
42 public UML2CompareTestProfileSwitch() {
43 if (modelPackage == null) {
44 modelPackage = UML2CompareTestProfilePackage.eINSTANCE;
48 /**
49 * Checks whether this is a switch for the given package.
50 * <!-- begin-user-doc -->
51 * <!-- end-user-doc -->
52 * @parameter ePackage the package in question.
53 * @return whether this is a switch for the given package.
54 * @generated
56 @Override
57 protected boolean isSwitchFor(EPackage ePackage) {
58 return ePackage == modelPackage;
61 /**
62 * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
63 * <!-- begin-user-doc --> <!-- end-user-doc -->
64 * @return the first non-null result returned by a <code>caseXXX</code> call.
65 * @generated
67 @Override
68 protected T doSwitch(int classifierID, EObject theEObject) {
69 switch (classifierID) {
70 case UML2CompareTestProfilePackage.ACLICHE: {
71 ACliche aCliche = (ACliche)theEObject;
72 T result = caseACliche(aCliche);
73 if (result == null) result = defaultCase(theEObject);
74 return result;
76 case UML2CompareTestProfilePackage.ACLICHE2: {
77 ACliche2 aCliche2 = (ACliche2)theEObject;
78 T result = caseACliche2(aCliche2);
79 if (result == null) result = defaultCase(theEObject);
80 return result;
82 case UML2CompareTestProfilePackage.ACLICHE3: {
83 ACliche3 aCliche3 = (ACliche3)theEObject;
84 T result = caseACliche3(aCliche3);
85 if (result == null) result = defaultCase(theEObject);
86 return result;
88 default: return defaultCase(theEObject);
92 /**
93 * Returns the result of interpreting the object as an instance of '<em>ACliche</em>'.
94 * <!-- begin-user-doc
95 * --> This implementation returns null; returning a non-null result will terminate the switch. <!--
96 * end-user-doc -->
97 * @param object the target of the switch.
98 * @return the result of interpreting the object as an instance of '<em>ACliche</em>'.
99 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
100 * @generated
102 public T caseACliche(ACliche object) {
103 return null;
107 * Returns the result of interpreting the object as an instance of '<em>ACliche2</em>'.
108 * <!-- begin-user-doc -->
109 * This implementation returns null;
110 * returning a non-null result will terminate the switch.
111 * <!-- end-user-doc -->
112 * @param object the target of the switch.
113 * @return the result of interpreting the object as an instance of '<em>ACliche2</em>'.
114 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
115 * @generated
117 public T caseACliche2(ACliche2 object) {
118 return null;
122 * Returns the result of interpreting the object as an instance of '<em>ACliche3</em>'.
123 * <!-- begin-user-doc -->
124 * This implementation returns null;
125 * returning a non-null result will terminate the switch.
126 * <!-- end-user-doc -->
127 * @param object the target of the switch.
128 * @return the result of interpreting the object as an instance of '<em>ACliche3</em>'.
129 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
130 * @generated
132 public T caseACliche3(ACliche3 object) {
133 return null;
137 * Returns the result of interpreting the object as an instance of '<em>EObject</em>'.
138 * <!-- begin-user-doc
139 * --> This implementation returns null; returning a non-null result will terminate the switch, but this
140 * is the last case anyway. <!-- end-user-doc -->
141 * @param object the target of the switch.
142 * @return the result of interpreting the object as an instance of '<em>EObject</em>'.
143 * @see #doSwitch(org.eclipse.emf.ecore.EObject)
144 * @generated
146 @Override
147 public T defaultCase(EObject object) {
148 return null;
151 } // UML2CompareTestProfileSwitch