Skip to content

Package: KeyattributedmrAdapterFactory$1

KeyattributedmrAdapterFactory$1

nameinstructionbranchcomplexitylinemethod
caseDomainModelReference(VDomainModelReference)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
caseFeaturePathDomainModelReference(VFeaturePathDomainModelReference)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
caseKeyAttributeDomainModelReference(VKeyAttributeDomainModelReference)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
defaultCase(EObject)
M: 4 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%
{...}
M: 6 C: 0
0%
M: 0 C: 0
100%
M: 1 C: 0
0%
M: 1 C: 0
0%
M: 1 C: 0
0%

Coverage

1: /**
2: * Copyright (c) 2011-2014 EclipseSource Muenchen GmbH and others.
3: *
4: * All rights reserved. This program and the accompanying materials
5: * are made available under the terms of the Eclipse Public License 2.0
6: * which accompanies this distribution, and is available at
7: * https://www.eclipse.org/legal/epl-2.0/
8: *
9: * SPDX-License-Identifier: EPL-2.0
10: *
11: * Contributors:
12: * Eugen Neufeld - initial API and implementation
13: */
14: package org.eclipse.emf.ecp.view.spi.keyattributedmr.model.util;
15:
16: import org.eclipse.emf.common.notify.Adapter;
17: import org.eclipse.emf.common.notify.Notifier;
18: import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl;
19: import org.eclipse.emf.ecore.EObject;
20: import org.eclipse.emf.ecp.view.spi.keyattributedmr.model.VKeyAttributeDomainModelReference;
21: import org.eclipse.emf.ecp.view.spi.keyattributedmr.model.VKeyattributedmrPackage;
22: import org.eclipse.emf.ecp.view.spi.model.VDomainModelReference;
23: import org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference;
24:
25: /**
26: * <!-- begin-user-doc --> The <b>Adapter Factory</b> for the model. It provides
27: * an adapter <code>createXXX</code> method for each class of the model. <!--
28: * end-user-doc -->
29: *
30: * @see org.eclipse.emf.ecp.view.spi.keyattributedmr.model.VKeyattributedmrPackage
31: * @generated
32: */
33: public class KeyattributedmrAdapterFactory extends AdapterFactoryImpl {
34:         /**
35:          * The cached model package.
36:          * <!-- begin-user-doc --> <!-- end-user-doc -->
37:          *
38:          * @generated
39:          */
40:         protected static VKeyattributedmrPackage modelPackage;
41:
42:         /**
43:          * Creates an instance of the adapter factory.
44:          * <!-- begin-user-doc --> <!--
45:          * end-user-doc -->
46:          *
47:          * @generated
48:          */
49:         public KeyattributedmrAdapterFactory() {
50:                 if (modelPackage == null) {
51:                         modelPackage = VKeyattributedmrPackage.eINSTANCE;
52:                 }
53:         }
54:
55:         /**
56:          * Returns whether this factory is applicable for the type of the object.
57:          * <!-- begin-user-doc --> This implementation returns <code>true</code> if
58:          * the object is either the model's package or is an instance object of the
59:          * model. <!-- end-user-doc -->
60:          *
61:          * @return whether this factory is applicable for the type of the object.
62:          * @generated
63:          */
64:         @Override
65:         public boolean isFactoryForType(Object object) {
66:                 if (object == modelPackage) {
67:                         return true;
68:                 }
69:                 if (object instanceof EObject) {
70:                         return ((EObject) object).eClass().getEPackage() == modelPackage;
71:                 }
72:                 return false;
73:         }
74:
75:         /**
76:          * The switch that delegates to the <code>createXXX</code> methods. <!--
77:          * begin-user-doc --> <!-- end-user-doc -->
78:          *
79:          * @generated
80:          */
81:         protected KeyattributedmrSwitch<Adapter> modelSwitch = new KeyattributedmrSwitch<Adapter>() {
82:                 @Override
83:                 public Adapter caseKeyAttributeDomainModelReference(VKeyAttributeDomainModelReference object) {
84:                         return createKeyAttributeDomainModelReferenceAdapter();
85:                 }
86:
87:                 @Override
88:                 public Adapter caseDomainModelReference(VDomainModelReference object) {
89:                         return createDomainModelReferenceAdapter();
90:                 }
91:
92:                 @Override
93:                 public Adapter caseFeaturePathDomainModelReference(VFeaturePathDomainModelReference object) {
94:                         return createFeaturePathDomainModelReferenceAdapter();
95:                 }
96:
97:                 @Override
98:                 public Adapter defaultCase(EObject object) {
99:                         return createEObjectAdapter();
100:                 }
101:         };
102:
103:         /**
104:          * Creates an adapter for the <code>target</code>.
105:          * <!-- begin-user-doc -->
106:          * <!-- end-user-doc -->
107:          *
108:          * @param target the object to adapt.
109:          * @return the adapter for the <code>target</code>.
110:          * @generated
111:          */
112:         @Override
113:         public Adapter createAdapter(Notifier target) {
114:                 return modelSwitch.doSwitch((EObject) target);
115:         }
116:
117:         /**
118:          * Creates a new adapter for an object of class '
119:          * {@link org.eclipse.emf.ecp.view.spi.keyattributedmr.model.VKeyAttributeDomainModelReference
120:          * <em>Key Attribute Domain Model Reference</em>}'.
121:          * <!-- begin-user-doc -->
122:          * This default implementation returns null so that we can easily ignore
123:          * cases; it's useful to ignore a case when inheritance will catch all the
124:          * cases anyway. <!-- end-user-doc -->
125:          *
126:          * @return the new adapter.
127:          * @see org.eclipse.emf.ecp.view.spi.keyattributedmr.model.VKeyAttributeDomainModelReference
128:          * @generated
129:          */
130:         public Adapter createKeyAttributeDomainModelReferenceAdapter() {
131:                 return null;
132:         }
133:
134:         /**
135:          * Creates a new adapter for an object of class '{@link org.eclipse.emf.ecp.view.spi.model.VDomainModelReference
136:          * <em>Domain Model Reference</em>}'.
137:          * <!-- begin-user-doc --> This default
138:          * implementation returns null so that we can easily ignore cases; it's
139:          * useful to ignore a case when inheritance will catch all the cases anyway.
140:          * <!-- end-user-doc -->
141:          *
142:          * @return the new adapter.
143:          * @see org.eclipse.emf.ecp.view.spi.model.VDomainModelReference
144:          * @generated
145:          */
146:         public Adapter createDomainModelReferenceAdapter() {
147:                 return null;
148:         }
149:
150:         /**
151:          * Creates a new adapter for an object of class '
152:          * {@link org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference
153:          * <em>Feature Path Domain Model Reference</em>}'.
154:          * <!-- begin-user-doc -->
155:          * This default implementation returns null so that we can easily ignore
156:          * cases; it's useful to ignore a case when inheritance will catch all the
157:          * cases anyway. <!-- end-user-doc -->
158:          *
159:          * @return the new adapter.
160:          * @see org.eclipse.emf.ecp.view.spi.model.VFeaturePathDomainModelReference
161:          * @generated
162:          */
163:         public Adapter createFeaturePathDomainModelReferenceAdapter() {
164:                 return null;
165:         }
166:
167:         /**
168:          * Creates a new adapter for the default case.
169:          * <!-- begin-user-doc --> This
170:          * default implementation returns null. <!-- end-user-doc -->
171:          *
172:          * @return the new adapter.
173:          * @generated
174:          */
175:         public Adapter createEObjectAdapter() {
176:                 return null;
177:         }
178:
179: } // KeyattributedmrAdapterFactory