EMMA Coverage Report (generated Sun Feb 05 10:43:15 CET 2012)
[all classes][EssentialOCL.impl]

COVERAGE SUMMARY FOR SOURCE FILE [CollectionLiteralPartImpl.java]

nameclass, %method, %block, %line, %
CollectionLiteralPartImpl.java0%   (0/1)0%   (0/12)0%   (0/188)0%   (0/47)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class CollectionLiteralPartImpl0%   (0/1)0%   (0/12)0%   (0/188)0%   (0/47)
CollectionLiteralPartImpl (): void 0%   (0/1)0%   (0/3)0%   (0/2)
basicSetCollectionLiteralExp (CollectionLiteralExp, NotificationChain): Notif... 0%   (0/1)0%   (0/9)0%   (0/2)
eBasicRemoveFromContainerFeature (NotificationChain): NotificationChain 0%   (0/1)0%   (0/15)0%   (0/3)
eGet (int, boolean, boolean): Object 0%   (0/1)0%   (0/11)0%   (0/3)
eInverseAdd (InternalEObject, int, NotificationChain): NotificationChain 0%   (0/1)0%   (0/21)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/13)0%   (0/3)
eSet (int, Object): void 0%   (0/1)0%   (0/12)0%   (0/5)
eStaticClass (): EClass 0%   (0/1)0%   (0/2)0%   (0/1)
eUnset (int): void 0%   (0/1)0%   (0/10)0%   (0/5)
getCollectionLiteralExp (): CollectionLiteralExp 0%   (0/1)0%   (0/10)0%   (0/2)
setCollectionLiteralExp (CollectionLiteralExp): void 0%   (0/1)0%   (0/69)0%   (0/13)

1/**
2 * <copyright>
3 * </copyright>
4 *
5 * $Id$
6 */
7package EssentialOCL.impl;
8 
9import EMOF.impl.TypedElementImpl;
10 
11import EssentialOCL.CollectionLiteralExp;
12import EssentialOCL.CollectionLiteralPart;
13import EssentialOCL.EssentialOCLPackage;
14 
15import org.eclipse.emf.common.notify.Notification;
16import org.eclipse.emf.common.notify.NotificationChain;
17 
18import org.eclipse.emf.ecore.EClass;
19import org.eclipse.emf.ecore.InternalEObject;
20 
21import org.eclipse.emf.ecore.impl.ENotificationImpl;
22 
23import org.eclipse.emf.ecore.util.EcoreUtil;
24 
25/**
26 * <!-- begin-user-doc -->
27 * An implementation of the model object '<em><b>Collection Literal Part</b></em>'.
28 * <!-- end-user-doc -->
29 * <p>
30 * The following features are implemented:
31 * <ul>
32 *   <li>{@link EssentialOCL.impl.CollectionLiteralPartImpl#getCollectionLiteralExp <em>Collection Literal Exp</em>}</li>
33 * </ul>
34 * </p>
35 *
36 * @generated
37 */
38public abstract class CollectionLiteralPartImpl extends TypedElementImpl implements CollectionLiteralPart {
39        /**
40         * <!-- begin-user-doc -->
41         * <!-- end-user-doc -->
42         * @generated
43         */
44        protected CollectionLiteralPartImpl() {
45                super();
46        }
47 
48        /**
49         * <!-- begin-user-doc -->
50         * <!-- end-user-doc -->
51         * @generated
52         */
53        @Override
54        protected EClass eStaticClass() {
55                return EssentialOCLPackage.Literals.COLLECTION_LITERAL_PART;
56        }
57 
58        /**
59         * <!-- begin-user-doc -->
60         * <!-- end-user-doc -->
61         * @generated
62         */
63        public CollectionLiteralExp getCollectionLiteralExp() {
64                if (eContainerFeatureID() != EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP) return null;
65                return (CollectionLiteralExp)eContainer();
66        }
67 
68        /**
69         * <!-- begin-user-doc -->
70         * <!-- end-user-doc -->
71         * @generated
72         */
73        public NotificationChain basicSetCollectionLiteralExp(CollectionLiteralExp newCollectionLiteralExp, NotificationChain msgs) {
74                msgs = eBasicSetContainer((InternalEObject)newCollectionLiteralExp, EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP, msgs);
75                return msgs;
76        }
77 
78        /**
79         * <!-- begin-user-doc -->
80         * <!-- end-user-doc -->
81         * @generated
82         */
83        public void setCollectionLiteralExp(CollectionLiteralExp newCollectionLiteralExp) {
84                if (newCollectionLiteralExp != eInternalContainer() || (eContainerFeatureID() != EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP && newCollectionLiteralExp != null)) {
85                        if (EcoreUtil.isAncestor(this, newCollectionLiteralExp))
86                                throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
87                        NotificationChain msgs = null;
88                        if (eInternalContainer() != null)
89                                msgs = eBasicRemoveFromContainer(msgs);
90                        if (newCollectionLiteralExp != null)
91                                msgs = ((InternalEObject)newCollectionLiteralExp).eInverseAdd(this, EssentialOCLPackage.COLLECTION_LITERAL_EXP__PART, CollectionLiteralExp.class, msgs);
92                        msgs = basicSetCollectionLiteralExp(newCollectionLiteralExp, msgs);
93                        if (msgs != null) msgs.dispatch();
94                }
95                else if (eNotificationRequired())
96                        eNotify(new ENotificationImpl(this, Notification.SET, EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP, newCollectionLiteralExp, newCollectionLiteralExp));
97        }
98 
99        /**
100         * <!-- begin-user-doc -->
101         * <!-- end-user-doc -->
102         * @generated
103         */
104        @Override
105        public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
106                switch (featureID) {
107                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
108                                if (eInternalContainer() != null)
109                                        msgs = eBasicRemoveFromContainer(msgs);
110                                return basicSetCollectionLiteralExp((CollectionLiteralExp)otherEnd, msgs);
111                }
112                return super.eInverseAdd(otherEnd, featureID, msgs);
113        }
114 
115        /**
116         * <!-- begin-user-doc -->
117         * <!-- end-user-doc -->
118         * @generated
119         */
120        @Override
121        public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
122                switch (featureID) {
123                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
124                                return basicSetCollectionLiteralExp(null, msgs);
125                }
126                return super.eInverseRemove(otherEnd, featureID, msgs);
127        }
128 
129        /**
130         * <!-- begin-user-doc -->
131         * <!-- end-user-doc -->
132         * @generated
133         */
134        @Override
135        public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
136                switch (eContainerFeatureID()) {
137                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
138                                return eInternalContainer().eInverseRemove(this, EssentialOCLPackage.COLLECTION_LITERAL_EXP__PART, CollectionLiteralExp.class, msgs);
139                }
140                return super.eBasicRemoveFromContainerFeature(msgs);
141        }
142 
143        /**
144         * <!-- begin-user-doc -->
145         * <!-- end-user-doc -->
146         * @generated
147         */
148        @Override
149        public Object eGet(int featureID, boolean resolve, boolean coreType) {
150                switch (featureID) {
151                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
152                                return getCollectionLiteralExp();
153                }
154                return super.eGet(featureID, resolve, coreType);
155        }
156 
157        /**
158         * <!-- begin-user-doc -->
159         * <!-- end-user-doc -->
160         * @generated
161         */
162        @Override
163        public void eSet(int featureID, Object newValue) {
164                switch (featureID) {
165                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
166                                setCollectionLiteralExp((CollectionLiteralExp)newValue);
167                                return;
168                }
169                super.eSet(featureID, newValue);
170        }
171 
172        /**
173         * <!-- begin-user-doc -->
174         * <!-- end-user-doc -->
175         * @generated
176         */
177        @Override
178        public void eUnset(int featureID) {
179                switch (featureID) {
180                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
181                                setCollectionLiteralExp((CollectionLiteralExp)null);
182                                return;
183                }
184                super.eUnset(featureID);
185        }
186 
187        /**
188         * <!-- begin-user-doc -->
189         * <!-- end-user-doc -->
190         * @generated
191         */
192        @Override
193        public boolean eIsSet(int featureID) {
194                switch (featureID) {
195                        case EssentialOCLPackage.COLLECTION_LITERAL_PART__COLLECTION_LITERAL_EXP:
196                                return getCollectionLiteralExp() != null;
197                }
198                return super.eIsSet(featureID);
199        }
200 
201} //CollectionLiteralPartImpl

[all classes][EssentialOCL.impl]
EMMA 2.0.9414 (unsupported private build) (C) Vladimir Roubtsov