EMMA Coverage Report (generated Sun Feb 05 10:43:15 CET 2012)
[all classes][de.uka.ipd.sdq.pcm.repository.impl]

COVERAGE SUMMARY FOR SOURCE FILE [ProvidesComponentTypeImpl.java]

nameclass, %method, %block, %line, %
ProvidesComponentTypeImpl.java0%   (0/1)0%   (0/4)0%   (0/70)0%   (0/22)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class ProvidesComponentTypeImpl0%   (0/1)0%   (0/4)0%   (0/70)0%   (0/22)
<static initializer> 0%   (0/1)0%   (0/3)0%   (0/2)
AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType (Diagnostic... 0%   (0/1)0%   (0/62)0%   (0/17)
ProvidesComponentTypeImpl (): void 0%   (0/1)0%   (0/3)0%   (0/2)
eStaticClass (): EClass 0%   (0/1)0%   (0/2)0%   (0/1)

1/**
2 * Copyright 2005-2009 by SDQ, IPD, University of Karlsruhe, Germany
3 *
4 * $Id$
5 */
6package de.uka.ipd.sdq.pcm.repository.impl;
7 
8import java.util.Map;
9 
10import org.eclipse.emf.common.util.BasicDiagnostic;
11import org.eclipse.emf.common.util.Diagnostic;
12import org.eclipse.emf.common.util.DiagnosticChain;
13import org.eclipse.emf.ecore.EClass;
14import org.eclipse.emf.ecore.plugin.EcorePlugin;
15import org.eclipse.emf.ecore.util.EObjectValidator;
16import org.eclipse.ocl.ParserException;
17import org.eclipse.ocl.ecore.Constraint;
18import org.eclipse.ocl.ecore.OCL;
19 
20import de.uka.ipd.sdq.pcm.repository.ProvidesComponentType;
21import de.uka.ipd.sdq.pcm.repository.RepositoryPackage;
22import de.uka.ipd.sdq.pcm.repository.util.RepositoryValidator;
23 
24/**
25 * <!-- begin-user-doc -->
26 * An implementation of the model object '<em><b>Provides Component Type</b></em>'.
27 * <!-- end-user-doc -->
28 * <p>
29 * </p>
30 *
31 * @generated
32 */
33public class ProvidesComponentTypeImpl extends RepositoryComponentImpl implements ProvidesComponentType {
34        /**
35         * <!-- begin-user-doc -->
36         * <!-- end-user-doc -->
37         * @generated
38         */
39        public static final String copyright = "Copyright 2005-2009 by SDQ, IPD, University of Karlsruhe, Germany";
40 
41        /**
42         * <!-- begin-user-doc -->
43         * <!-- end-user-doc -->
44         * @generated
45         */
46        protected ProvidesComponentTypeImpl() {
47                super();
48        }
49 
50        /**
51         * <!-- begin-user-doc -->
52         * <!-- end-user-doc -->
53         * @generated
54         */
55        @Override
56        protected EClass eStaticClass() {
57                return RepositoryPackage.Literals.PROVIDES_COMPONENT_TYPE;
58        }
59 
60        /**
61         * The cached OCL expression body for the '{@link #AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) <em>At Least One Interface Has To Be Provided By AUsefull Provides Component Type</em>}' operation.
62         * <!-- begin-user-doc -->
63         * <!-- end-user-doc -->
64         * @see #AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map)
65         * @generated
66         * @ordered
67         */
68        protected static final String AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE__DIAGNOSTIC_CHAIN_MAP__EOCL_EXP = "self.oclIsTypeOf(ProvidesComponentType)\n"+"implies\n"+"self.providedRoles_InterfaceProvidingEntity->size() >= 1";
69        /**
70         * The cached OCL invariant for the '{@link #AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) <em>At Least One Interface Has To Be Provided By AUsefull Provides Component Type</em>}' invariant operation.
71         * <!-- begin-user-doc -->
72         * <!-- end-user-doc -->
73         * @see #AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map)
74         * @generated
75         * @ordered
76         */
77        protected static Constraint AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE__DIAGNOSTIC_CHAIN_MAP__EOCL_INV;
78 
79        /**
80         * <!-- begin-user-doc -->
81         * <!-- end-user-doc -->
82         * @generated
83         */
84        public boolean AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType(DiagnosticChain diagnostics, Map<Object, Object> context) {
85                if (AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE__DIAGNOSTIC_CHAIN_MAP__EOCL_INV == null) {
86                        OCL.Helper helper = EOCL_ENV.createOCLHelper();
87                        helper.setContext(RepositoryPackage.Literals.PROVIDES_COMPONENT_TYPE);
88                        try {
89                                AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE__DIAGNOSTIC_CHAIN_MAP__EOCL_INV = helper.createInvariant(AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE__DIAGNOSTIC_CHAIN_MAP__EOCL_EXP);
90                        }
91                        catch (ParserException pe) {
92                                throw new UnsupportedOperationException(pe.getLocalizedMessage());
93                        }
94                }
95                if (!EOCL_ENV.createQuery(AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE__DIAGNOSTIC_CHAIN_MAP__EOCL_INV).check(this)) {
96                        if (diagnostics != null) {
97                                diagnostics.add
98                                        (new BasicDiagnostic
99                                                (Diagnostic.ERROR,
100                                                 RepositoryValidator.DIAGNOSTIC_SOURCE,
101                                                 RepositoryValidator.PROVIDES_COMPONENT_TYPE__AT_LEAST_ONE_INTERFACE_HAS_TO_BE_PROVIDED_BY_AUSEFULL_PROVIDES_COMPONENT_TYPE,
102                                                 EcorePlugin.INSTANCE.getString("_UI_GenericInvariant_diagnostic", new Object[] { "AtLeastOneInterfaceHasToBeProvidedByAUsefullProvidesComponentType", EObjectValidator.getObjectLabel(this, context) }),
103                                                 new Object [] { this }));
104                        }
105                        return false;
106                }
107                return true;
108        }
109 
110        /**
111         * The cached environment for evaluating OCL expressions.
112         * <!-- begin-user-doc -->
113         * <!-- end-user-doc -->
114         * @generated
115         * @ordered
116         */
117        protected static final OCL EOCL_ENV = OCL.newInstance();
118 
119} //ProvidesComponentTypeImpl

[all classes][de.uka.ipd.sdq.pcm.repository.impl]
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov