Skip to content

Package: EdaptTestAPackageImpl

EdaptTestAPackageImpl

nameinstructionbranchcomplexitylinemethod
EdaptTestAPackageImpl()
M: 0 C: 14
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 5
100%
M: 0 C: 1
100%
createPackageContents()
M: 0 C: 13
100%
M: 0 C: 2
100%
M: 0 C: 2
100%
M: 0 C: 5
100%
M: 0 C: 1
100%
getA()
M: 0 C: 3
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
getAFactory()
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%
init()
M: 21 C: 159
88%
M: 11 C: 11
50%
M: 11 C: 1
8%
M: 10 C: 55
85%
M: 0 C: 1
100%
initializePackageContents()
M: 0 C: 31
100%
M: 0 C: 2
100%
M: 0 C: 2
100%
M: 0 C: 9
100%
M: 0 C: 1
100%
static {...}
M: 0 C: 3
100%
M: 0 C: 0
100%
M: 0 C: 1
100%
M: 0 C: 1
100%
M: 0 C: 1
100%

Coverage

1: /**
2: * Copyright (c) 2011-2013 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: */
13: package org.eclipse.emf.ecp.view.edapt.util.test.model.a.impl;
14:
15: import org.eclipse.emf.ecore.EClass;
16: import org.eclipse.emf.ecore.EPackage;
17: import org.eclipse.emf.ecore.impl.EPackageImpl;
18: import org.eclipse.emf.ecp.view.edapt.util.test.model.a.EdaptTestA;
19: import org.eclipse.emf.ecp.view.edapt.util.test.model.a.EdaptTestAFactory;
20: import org.eclipse.emf.ecp.view.edapt.util.test.model.a.EdaptTestAPackage;
21: import org.eclipse.emf.ecp.view.edapt.util.test.model.b.EdaptTestBPackage;
22: import org.eclipse.emf.ecp.view.edapt.util.test.model.b.impl.EdaptTestBPackageImpl;
23: import org.eclipse.emf.ecp.view.edapt.util.test.model.c.EdaptTestCPackage;
24: import org.eclipse.emf.ecp.view.edapt.util.test.model.c.impl.EdaptTestCPackageImpl;
25: import org.eclipse.emf.ecp.view.edapt.util.test.model.d.EdaptTestDPackage;
26: import org.eclipse.emf.ecp.view.edapt.util.test.model.d.impl.EdaptTestDPackageImpl;
27: import org.eclipse.emf.ecp.view.edapt.util.test.model.e.EdaptTestEPackage;
28: import org.eclipse.emf.ecp.view.edapt.util.test.model.e.impl.EdaptTestEPackageImpl;
29: import org.eclipse.emf.ecp.view.edapt.util.test.model.f.EdaptTestFPackage;
30: import org.eclipse.emf.ecp.view.edapt.util.test.model.f.impl.EdaptTestFPackageImpl;
31: import org.eclipse.emf.ecp.view.edapt.util.test.model.w.EdaptTestWPackage;
32: import org.eclipse.emf.ecp.view.edapt.util.test.model.w.impl.EdaptTestWPackageImpl;
33: import org.eclipse.emf.ecp.view.edapt.util.test.model.x.EdaptTestXPackage;
34: import org.eclipse.emf.ecp.view.edapt.util.test.model.x.impl.EdaptTestXPackageImpl;
35: import org.eclipse.emf.ecp.view.edapt.util.test.model.y.EdaptTestYPackage;
36: import org.eclipse.emf.ecp.view.edapt.util.test.model.y.impl.EdaptTestYPackageImpl;
37: import org.eclipse.emf.ecp.view.edapt.util.test.model.z.EdaptTestZPackage;
38: import org.eclipse.emf.ecp.view.edapt.util.test.model.z.impl.EdaptTestZPackageImpl;
39:
40: /**
41: * <!-- begin-user-doc -->
42: * An implementation of the model <b>Package</b>.
43: * <!-- end-user-doc -->
44: *
45: * @generated
46: */
47: public class EdaptTestAPackageImpl extends EPackageImpl implements EdaptTestAPackage {
48:         /**
49:          * <!-- begin-user-doc -->
50:          * <!-- end-user-doc -->
51:          *
52:          * @generated
53:          */
54:         private EClass aEClass = null;
55:
56:         /**
57:          * Creates an instance of the model <b>Package</b>, registered with
58:          * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
59:          * package URI value.
60:          * <p>
61:          * Note: the correct way to create the package is via the static
62:          * factory method {@link #init init()}, which also performs
63:          * initialization of the package, or returns the registered package,
64:          * if one already exists.
65:          * <!-- begin-user-doc -->
66:          * <!-- end-user-doc -->
67:          *
68:          * @see org.eclipse.emf.ecore.EPackage.Registry
69:          * @see org.eclipse.emf.ecp.view.edapt.util.test.model.a.EdaptTestAPackage#eNS_URI
70:          * @see #init()
71:          * @generated
72:          */
73:         private EdaptTestAPackageImpl() {
74:                 super(eNS_URI, EdaptTestAFactory.eINSTANCE);
75:         }
76:
77:         /**
78:          * <!-- begin-user-doc -->
79:          * <!-- end-user-doc -->
80:          *
81:          * @generated
82:          */
83:         private static boolean isInited = false;
84:
85:         /**
86:          * Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends.
87:          *
88:          * <p>
89:          * This method is used to initialize {@link EdaptTestAPackage#eINSTANCE} when that field is accessed.
90:          * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package.
91:          * <!-- begin-user-doc -->
92:          * <!-- end-user-doc -->
93:          *
94:          * @see #eNS_URI
95:          * @see #createPackageContents()
96:          * @see #initializePackageContents()
97:          * @generated
98:          */
99:         public static EdaptTestAPackage init() {
100:•                if (isInited) {
101:                         return (EdaptTestAPackage) EPackage.Registry.INSTANCE.getEPackage(EdaptTestAPackage.eNS_URI);
102:                 }
103:
104:                 // Obtain or create and register package
105:                 final EdaptTestAPackageImpl theAPackage = (EdaptTestAPackageImpl) (EPackage.Registry.INSTANCE
106:•                        .get(eNS_URI) instanceof EdaptTestAPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI)
107:                                 : new EdaptTestAPackageImpl());
108:
109:                 isInited = true;
110:
111:                 // Obtain or create and register interdependencies
112:                 final EdaptTestBPackageImpl theBPackage = (EdaptTestBPackageImpl) (EPackage.Registry.INSTANCE
113:•                        .getEPackage(EdaptTestBPackage.eNS_URI) instanceof EdaptTestBPackageImpl
114:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestBPackage.eNS_URI)
115:                                 : EdaptTestBPackage.eINSTANCE);
116:                 final EdaptTestCPackageImpl theCPackage = (EdaptTestCPackageImpl) (EPackage.Registry.INSTANCE
117:•                        .getEPackage(EdaptTestCPackage.eNS_URI) instanceof EdaptTestCPackageImpl
118:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestCPackage.eNS_URI)
119:                                 : EdaptTestCPackage.eINSTANCE);
120:                 final EdaptTestDPackageImpl theDPackage = (EdaptTestDPackageImpl) (EPackage.Registry.INSTANCE
121:•                        .getEPackage(EdaptTestDPackage.eNS_URI) instanceof EdaptTestDPackageImpl
122:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestDPackage.eNS_URI)
123:                                 : EdaptTestDPackage.eINSTANCE);
124:                 final EdaptTestEPackageImpl theEPackage = (EdaptTestEPackageImpl) (EPackage.Registry.INSTANCE
125:•                        .getEPackage(EdaptTestEPackage.eNS_URI) instanceof EdaptTestEPackageImpl
126:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestEPackage.eNS_URI)
127:                                 : EdaptTestEPackage.eINSTANCE);
128:                 final EdaptTestFPackageImpl theFPackage = (EdaptTestFPackageImpl) (EPackage.Registry.INSTANCE
129:•                        .getEPackage(EdaptTestFPackage.eNS_URI) instanceof EdaptTestFPackageImpl
130:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestFPackage.eNS_URI)
131:                                 : EdaptTestFPackage.eINSTANCE);
132:                 final EdaptTestWPackageImpl theWPackage = (EdaptTestWPackageImpl) (EPackage.Registry.INSTANCE
133:•                        .getEPackage(EdaptTestWPackage.eNS_URI) instanceof EdaptTestWPackageImpl
134:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestWPackage.eNS_URI)
135:                                 : EdaptTestWPackage.eINSTANCE);
136:                 final EdaptTestXPackageImpl theXPackage = (EdaptTestXPackageImpl) (EPackage.Registry.INSTANCE
137:•                        .getEPackage(EdaptTestXPackage.eNS_URI) instanceof EdaptTestXPackageImpl
138:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestXPackage.eNS_URI)
139:                                 : EdaptTestXPackage.eINSTANCE);
140:                 final EdaptTestYPackageImpl theYPackage = (EdaptTestYPackageImpl) (EPackage.Registry.INSTANCE
141:•                        .getEPackage(EdaptTestYPackage.eNS_URI) instanceof EdaptTestYPackageImpl
142:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestYPackage.eNS_URI)
143:                                 : EdaptTestYPackage.eINSTANCE);
144:                 final EdaptTestZPackageImpl theZPackage = (EdaptTestZPackageImpl) (EPackage.Registry.INSTANCE
145:•                        .getEPackage(EdaptTestZPackage.eNS_URI) instanceof EdaptTestZPackageImpl
146:                                 ? EPackage.Registry.INSTANCE.getEPackage(EdaptTestZPackage.eNS_URI)
147:                                 : EdaptTestZPackage.eINSTANCE);
148:
149:                 // Create package meta-data objects
150:                 theAPackage.createPackageContents();
151:                 theBPackage.createPackageContents();
152:                 theCPackage.createPackageContents();
153:                 theDPackage.createPackageContents();
154:                 theEPackage.createPackageContents();
155:                 theFPackage.createPackageContents();
156:                 theWPackage.createPackageContents();
157:                 theXPackage.createPackageContents();
158:                 theYPackage.createPackageContents();
159:                 theZPackage.createPackageContents();
160:
161:                 // Initialize created meta-data
162:                 theAPackage.initializePackageContents();
163:                 theBPackage.initializePackageContents();
164:                 theCPackage.initializePackageContents();
165:                 theDPackage.initializePackageContents();
166:                 theEPackage.initializePackageContents();
167:                 theFPackage.initializePackageContents();
168:                 theWPackage.initializePackageContents();
169:                 theXPackage.initializePackageContents();
170:                 theYPackage.initializePackageContents();
171:                 theZPackage.initializePackageContents();
172:
173:                 // Mark meta-data to indicate it can't be changed
174:                 theAPackage.freeze();
175:
176:                 // Update the registry and return the package
177:                 EPackage.Registry.INSTANCE.put(EdaptTestAPackage.eNS_URI, theAPackage);
178:                 return theAPackage;
179:         }
180:
181:         /**
182:          * <!-- begin-user-doc -->
183:          * <!-- end-user-doc -->
184:          *
185:          * @generated
186:          */
187:         @Override
188:         public EClass getA() {
189:                 return aEClass;
190:         }
191:
192:         /**
193:          * <!-- begin-user-doc -->
194:          * <!-- end-user-doc -->
195:          *
196:          * @generated
197:          */
198:         @Override
199:         public EdaptTestAFactory getAFactory() {
200:                 return (EdaptTestAFactory) getEFactoryInstance();
201:         }
202:
203:         /**
204:          * <!-- begin-user-doc -->
205:          * <!-- end-user-doc -->
206:          *
207:          * @generated
208:          */
209:         private boolean isCreated = false;
210:
211:         /**
212:          * Creates the meta-model objects for the package. This method is
213:          * guarded to have no affect on any invocation but its first.
214:          * <!-- begin-user-doc -->
215:          * <!-- end-user-doc -->
216:          *
217:          * @generated
218:          */
219:         public void createPackageContents() {
220:•                if (isCreated) {
221:                         return;
222:                 }
223:                 isCreated = true;
224:
225:                 // Create classes and their features
226:                 aEClass = createEClass(A);
227:         }
228:
229:         /**
230:          * <!-- begin-user-doc -->
231:          * <!-- end-user-doc -->
232:          *
233:          * @generated
234:          */
235:         private boolean isInitialized = false;
236:
237:         /**
238:          * Complete the initialization of the package and its meta-model. This
239:          * method is guarded to have no affect on any invocation but its first.
240:          * <!-- begin-user-doc -->
241:          * <!-- end-user-doc -->
242:          *
243:          * @generated
244:          */
245:         public void initializePackageContents() {
246:•                if (isInitialized) {
247:                         return;
248:                 }
249:                 isInitialized = true;
250:
251:                 // Initialize package
252:                 setName(eNAME);
253:                 setNsPrefix(eNS_PREFIX);
254:                 setNsURI(eNS_URI);
255:
256:                 // Create type parameters
257:
258:                 // Set bounds for type parameters
259:
260:                 // Add supertypes to classes
261:
262:                 // Initialize classes, features, and operations; add parameters
263:                 initEClass(aEClass, EdaptTestA.class, "A", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
264:
265:                 // Create resource
266:                 createResource(eNS_URI);
267:         }
268:
269: } // EdaptTestAPackageImpl