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

COVERAGE SUMMARY FOR SOURCE FILE [ResourceDemandImpl.java]

nameclass, %method, %block, %line, %
ResourceDemandImpl.java0%   (0/1)0%   (0/13)0%   (0/234)0%   (0/60)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class ResourceDemandImpl0%   (0/1)0%   (0/13)0%   (0/234)0%   (0/60)
ResourceDemandImpl (): void 0%   (0/1)0%   (0/3)0%   (0/2)
basicGetParametricResourceDemand_ResourceDemand (): ParametricResourceDemand 0%   (0/1)0%   (0/3)0%   (0/1)
basicSetSpecification_ResourceDemand (PCMRandomVariable, NotificationChain): ... 0%   (0/1)0%   (0/29)0%   (0/6)
eGet (int, boolean, boolean): Object 0%   (0/1)0%   (0/19)0%   (0/5)
eInverseRemove (InternalEObject, int, NotificationChain): NotificationChain 0%   (0/1)0%   (0/13)0%   (0/3)
eIsSet (int): boolean 0%   (0/1)0%   (0/20)0%   (0/4)
eSet (int, Object): void 0%   (0/1)0%   (0/17)0%   (0/7)
eStaticClass (): EClass 0%   (0/1)0%   (0/2)0%   (0/1)
eUnset (int): void 0%   (0/1)0%   (0/14)0%   (0/7)
getParametricResourceDemand_ResourceDemand (): ParametricResourceDemand 0%   (0/1)0%   (0/38)0%   (0/7)
getSpecification_ResourceDemand (): PCMRandomVariable 0%   (0/1)0%   (0/3)0%   (0/1)
setParametricResourceDemand_ResourceDemand (ParametricResourceDemand): void 0%   (0/1)0%   (0/21)0%   (0/5)
setSpecification_ResourceDemand (PCMRandomVariable): void 0%   (0/1)0%   (0/52)0%   (0/11)

1/**
2 * Copyright 2006, SDQ Group, University Karlsruhe (TH)
3 *
4 * $Id$
5 */
6package de.uka.ipd.sdq.context.computed_allocation.impl;
7 
8import org.eclipse.emf.common.notify.Notification;
9import org.eclipse.emf.common.notify.NotificationChain;
10import org.eclipse.emf.ecore.EClass;
11import org.eclipse.emf.ecore.InternalEObject;
12import org.eclipse.emf.ecore.impl.ENotificationImpl;
13import org.eclipse.emf.ecore.impl.EObjectImpl;
14 
15import de.uka.ipd.sdq.context.computed_allocation.ComputedAllocationPackage;
16import de.uka.ipd.sdq.context.computed_allocation.ResourceDemand;
17import de.uka.ipd.sdq.pcm.core.PCMRandomVariable;
18import de.uka.ipd.sdq.pcm.seff.seff_performance.ParametricResourceDemand;
19 
20/**
21 * <!-- begin-user-doc -->
22 * An implementation of the model object '<em><b>Resource Demand</b></em>'.
23 * <!-- end-user-doc -->
24 * <p>
25 * The following features are implemented:
26 * <ul>
27 *   <li>{@link de.uka.ipd.sdq.context.computed_allocation.impl.ResourceDemandImpl#getParametricResourceDemand_ResourceDemand <em>Parametric Resource Demand Resource Demand</em>}</li>
28 *   <li>{@link de.uka.ipd.sdq.context.computed_allocation.impl.ResourceDemandImpl#getSpecification_ResourceDemand <em>Specification Resource Demand</em>}</li>
29 * </ul>
30 * </p>
31 *
32 * @generated
33 */
34public class ResourceDemandImpl extends EObjectImpl implements ResourceDemand {
35        /**
36         * <!-- begin-user-doc -->
37         * <!-- end-user-doc -->
38         * @generated
39         */
40        public static final String copyright = "Copyright 2006, SDQ Group, University Karlsruhe (TH)";
41 
42        /**
43         * The cached value of the '{@link #getParametricResourceDemand_ResourceDemand() <em>Parametric Resource Demand Resource Demand</em>}' reference.
44         * <!-- begin-user-doc -->
45         * <!-- end-user-doc -->
46         * @see #getParametricResourceDemand_ResourceDemand()
47         * @generated
48         * @ordered
49         */
50        protected ParametricResourceDemand parametricResourceDemand_ResourceDemand;
51 
52        /**
53         * The cached value of the '{@link #getSpecification_ResourceDemand() <em>Specification Resource Demand</em>}' containment reference.
54         * <!-- begin-user-doc -->
55         * <!-- end-user-doc -->
56         * @see #getSpecification_ResourceDemand()
57         * @generated
58         * @ordered
59         */
60        protected PCMRandomVariable specification_ResourceDemand;
61 
62        /**
63         * <!-- begin-user-doc -->
64         * <!-- end-user-doc -->
65         * @generated
66         */
67        protected ResourceDemandImpl() {
68                super();
69        }
70 
71        /**
72         * <!-- begin-user-doc -->
73         * <!-- end-user-doc -->
74         * @generated
75         */
76        @Override
77        protected EClass eStaticClass() {
78                return ComputedAllocationPackage.Literals.RESOURCE_DEMAND;
79        }
80 
81        /**
82         * <!-- begin-user-doc -->
83         * <!-- end-user-doc -->
84         * @generated
85         */
86        public ParametricResourceDemand getParametricResourceDemand_ResourceDemand() {
87                if (parametricResourceDemand_ResourceDemand != null && parametricResourceDemand_ResourceDemand.eIsProxy()) {
88                        InternalEObject oldParametricResourceDemand_ResourceDemand = (InternalEObject)parametricResourceDemand_ResourceDemand;
89                        parametricResourceDemand_ResourceDemand = (ParametricResourceDemand)eResolveProxy(oldParametricResourceDemand_ResourceDemand);
90                        if (parametricResourceDemand_ResourceDemand != oldParametricResourceDemand_ResourceDemand) {
91                                if (eNotificationRequired())
92                                        eNotify(new ENotificationImpl(this, Notification.RESOLVE, ComputedAllocationPackage.RESOURCE_DEMAND__PARAMETRIC_RESOURCE_DEMAND_RESOURCE_DEMAND, oldParametricResourceDemand_ResourceDemand, parametricResourceDemand_ResourceDemand));
93                        }
94                }
95                return parametricResourceDemand_ResourceDemand;
96        }
97 
98        /**
99         * <!-- begin-user-doc -->
100         * <!-- end-user-doc -->
101         * @generated
102         */
103        public ParametricResourceDemand basicGetParametricResourceDemand_ResourceDemand() {
104                return parametricResourceDemand_ResourceDemand;
105        }
106 
107        /**
108         * <!-- begin-user-doc -->
109         * <!-- end-user-doc -->
110         * @generated
111         */
112        public void setParametricResourceDemand_ResourceDemand(ParametricResourceDemand newParametricResourceDemand_ResourceDemand) {
113                ParametricResourceDemand oldParametricResourceDemand_ResourceDemand = parametricResourceDemand_ResourceDemand;
114                parametricResourceDemand_ResourceDemand = newParametricResourceDemand_ResourceDemand;
115                if (eNotificationRequired())
116                        eNotify(new ENotificationImpl(this, Notification.SET, ComputedAllocationPackage.RESOURCE_DEMAND__PARAMETRIC_RESOURCE_DEMAND_RESOURCE_DEMAND, oldParametricResourceDemand_ResourceDemand, parametricResourceDemand_ResourceDemand));
117        }
118 
119        /**
120         * <!-- begin-user-doc -->
121         * <!-- end-user-doc -->
122         * @generated
123         */
124        public PCMRandomVariable getSpecification_ResourceDemand() {
125                return specification_ResourceDemand;
126        }
127 
128        /**
129         * <!-- begin-user-doc -->
130         * <!-- end-user-doc -->
131         * @generated
132         */
133        public NotificationChain basicSetSpecification_ResourceDemand(PCMRandomVariable newSpecification_ResourceDemand, NotificationChain msgs) {
134                PCMRandomVariable oldSpecification_ResourceDemand = specification_ResourceDemand;
135                specification_ResourceDemand = newSpecification_ResourceDemand;
136                if (eNotificationRequired()) {
137                        ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND, oldSpecification_ResourceDemand, newSpecification_ResourceDemand);
138                        if (msgs == null) msgs = notification; else msgs.add(notification);
139                }
140                return msgs;
141        }
142 
143        /**
144         * <!-- begin-user-doc -->
145         * <!-- end-user-doc -->
146         * @generated
147         */
148        public void setSpecification_ResourceDemand(PCMRandomVariable newSpecification_ResourceDemand) {
149                if (newSpecification_ResourceDemand != specification_ResourceDemand) {
150                        NotificationChain msgs = null;
151                        if (specification_ResourceDemand != null)
152                                msgs = ((InternalEObject)specification_ResourceDemand).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND, null, msgs);
153                        if (newSpecification_ResourceDemand != null)
154                                msgs = ((InternalEObject)newSpecification_ResourceDemand).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND, null, msgs);
155                        msgs = basicSetSpecification_ResourceDemand(newSpecification_ResourceDemand, msgs);
156                        if (msgs != null) msgs.dispatch();
157                }
158                else if (eNotificationRequired())
159                        eNotify(new ENotificationImpl(this, Notification.SET, ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND, newSpecification_ResourceDemand, newSpecification_ResourceDemand));
160        }
161 
162        /**
163         * <!-- begin-user-doc -->
164         * <!-- end-user-doc -->
165         * @generated
166         */
167        @Override
168        public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
169                switch (featureID) {
170                        case ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND:
171                                return basicSetSpecification_ResourceDemand(null, msgs);
172                }
173                return super.eInverseRemove(otherEnd, featureID, msgs);
174        }
175 
176        /**
177         * <!-- begin-user-doc -->
178         * <!-- end-user-doc -->
179         * @generated
180         */
181        @Override
182        public Object eGet(int featureID, boolean resolve, boolean coreType) {
183                switch (featureID) {
184                        case ComputedAllocationPackage.RESOURCE_DEMAND__PARAMETRIC_RESOURCE_DEMAND_RESOURCE_DEMAND:
185                                if (resolve) return getParametricResourceDemand_ResourceDemand();
186                                return basicGetParametricResourceDemand_ResourceDemand();
187                        case ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND:
188                                return getSpecification_ResourceDemand();
189                }
190                return super.eGet(featureID, resolve, coreType);
191        }
192 
193        /**
194         * <!-- begin-user-doc -->
195         * <!-- end-user-doc -->
196         * @generated
197         */
198        @Override
199        public void eSet(int featureID, Object newValue) {
200                switch (featureID) {
201                        case ComputedAllocationPackage.RESOURCE_DEMAND__PARAMETRIC_RESOURCE_DEMAND_RESOURCE_DEMAND:
202                                setParametricResourceDemand_ResourceDemand((ParametricResourceDemand)newValue);
203                                return;
204                        case ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND:
205                                setSpecification_ResourceDemand((PCMRandomVariable)newValue);
206                                return;
207                }
208                super.eSet(featureID, newValue);
209        }
210 
211        /**
212         * <!-- begin-user-doc -->
213         * <!-- end-user-doc -->
214         * @generated
215         */
216        @Override
217        public void eUnset(int featureID) {
218                switch (featureID) {
219                        case ComputedAllocationPackage.RESOURCE_DEMAND__PARAMETRIC_RESOURCE_DEMAND_RESOURCE_DEMAND:
220                                setParametricResourceDemand_ResourceDemand((ParametricResourceDemand)null);
221                                return;
222                        case ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND:
223                                setSpecification_ResourceDemand((PCMRandomVariable)null);
224                                return;
225                }
226                super.eUnset(featureID);
227        }
228 
229        /**
230         * <!-- begin-user-doc -->
231         * <!-- end-user-doc -->
232         * @generated
233         */
234        @Override
235        public boolean eIsSet(int featureID) {
236                switch (featureID) {
237                        case ComputedAllocationPackage.RESOURCE_DEMAND__PARAMETRIC_RESOURCE_DEMAND_RESOURCE_DEMAND:
238                                return parametricResourceDemand_ResourceDemand != null;
239                        case ComputedAllocationPackage.RESOURCE_DEMAND__SPECIFICATION_RESOURCE_DEMAND:
240                                return specification_ResourceDemand != null;
241                }
242                return super.eIsSet(featureID);
243        }
244 
245} //ResourceDemandImpl

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