diff options
Diffstat (limited to 'Framework/hu.bme.mit.inf.dslreasoner.logic.model/ecore-gen/hu/bme/mit/inf/dslreasoner/logic/model/logicproblem/impl/ConstantAnnotationImpl.java')
-rw-r--r-- | Framework/hu.bme.mit.inf.dslreasoner.logic.model/ecore-gen/hu/bme/mit/inf/dslreasoner/logic/model/logicproblem/impl/ConstantAnnotationImpl.java | 211 |
1 files changed, 211 insertions, 0 deletions
diff --git a/Framework/hu.bme.mit.inf.dslreasoner.logic.model/ecore-gen/hu/bme/mit/inf/dslreasoner/logic/model/logicproblem/impl/ConstantAnnotationImpl.java b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/ecore-gen/hu/bme/mit/inf/dslreasoner/logic/model/logicproblem/impl/ConstantAnnotationImpl.java new file mode 100644 index 00000000..734ce70c --- /dev/null +++ b/Framework/hu.bme.mit.inf.dslreasoner.logic.model/ecore-gen/hu/bme/mit/inf/dslreasoner/logic/model/logicproblem/impl/ConstantAnnotationImpl.java | |||
@@ -0,0 +1,211 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.impl; | ||
4 | |||
5 | import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.Constant; | ||
6 | |||
7 | import hu.bme.mit.inf.dslreasoner.logic.model.logiclanguage.LogiclanguagePackage; | ||
8 | import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.ConstantAnnotation; | ||
9 | import hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.LogicproblemPackage; | ||
10 | |||
11 | import org.eclipse.emf.common.notify.Notification; | ||
12 | |||
13 | import org.eclipse.emf.common.notify.NotificationChain; | ||
14 | import org.eclipse.emf.ecore.EClass; | ||
15 | import org.eclipse.emf.ecore.InternalEObject; | ||
16 | |||
17 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
18 | |||
19 | /** | ||
20 | * <!-- begin-user-doc --> | ||
21 | * An implementation of the model object '<em><b>Constant Annotation</b></em>'. | ||
22 | * <!-- end-user-doc --> | ||
23 | * <p> | ||
24 | * The following features are implemented: | ||
25 | * </p> | ||
26 | * <ul> | ||
27 | * <li>{@link hu.bme.mit.inf.dslreasoner.logic.model.logicproblem.impl.ConstantAnnotationImpl#getTarget <em>Target</em>}</li> | ||
28 | * </ul> | ||
29 | * | ||
30 | * @generated | ||
31 | */ | ||
32 | public class ConstantAnnotationImpl extends AnnotationImpl implements ConstantAnnotation { | ||
33 | /** | ||
34 | * The cached value of the '{@link #getTarget() <em>Target</em>}' reference. | ||
35 | * <!-- begin-user-doc --> | ||
36 | * <!-- end-user-doc --> | ||
37 | * @see #getTarget() | ||
38 | * @generated | ||
39 | * @ordered | ||
40 | */ | ||
41 | protected Constant target; | ||
42 | |||
43 | /** | ||
44 | * <!-- begin-user-doc --> | ||
45 | * <!-- end-user-doc --> | ||
46 | * @generated | ||
47 | */ | ||
48 | protected ConstantAnnotationImpl() { | ||
49 | super(); | ||
50 | } | ||
51 | |||
52 | /** | ||
53 | * <!-- begin-user-doc --> | ||
54 | * <!-- end-user-doc --> | ||
55 | * @generated | ||
56 | */ | ||
57 | @Override | ||
58 | protected EClass eStaticClass() { | ||
59 | return LogicproblemPackage.Literals.CONSTANT_ANNOTATION; | ||
60 | } | ||
61 | |||
62 | /** | ||
63 | * <!-- begin-user-doc --> | ||
64 | * <!-- end-user-doc --> | ||
65 | * @generated | ||
66 | */ | ||
67 | public Constant getTarget() { | ||
68 | if (target != null && target.eIsProxy()) { | ||
69 | InternalEObject oldTarget = (InternalEObject)target; | ||
70 | target = (Constant)eResolveProxy(oldTarget); | ||
71 | if (target != oldTarget) { | ||
72 | if (eNotificationRequired()) | ||
73 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, LogicproblemPackage.CONSTANT_ANNOTATION__TARGET, oldTarget, target)); | ||
74 | } | ||
75 | } | ||
76 | return target; | ||
77 | } | ||
78 | |||
79 | /** | ||
80 | * <!-- begin-user-doc --> | ||
81 | * <!-- end-user-doc --> | ||
82 | * @generated | ||
83 | */ | ||
84 | public Constant basicGetTarget() { | ||
85 | return target; | ||
86 | } | ||
87 | |||
88 | /** | ||
89 | * <!-- begin-user-doc --> | ||
90 | * <!-- end-user-doc --> | ||
91 | * @generated | ||
92 | */ | ||
93 | public NotificationChain basicSetTarget(Constant newTarget, NotificationChain msgs) { | ||
94 | Constant oldTarget = target; | ||
95 | target = newTarget; | ||
96 | if (eNotificationRequired()) { | ||
97 | ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, LogicproblemPackage.CONSTANT_ANNOTATION__TARGET, oldTarget, newTarget); | ||
98 | if (msgs == null) msgs = notification; else msgs.add(notification); | ||
99 | } | ||
100 | return msgs; | ||
101 | } | ||
102 | |||
103 | /** | ||
104 | * <!-- begin-user-doc --> | ||
105 | * <!-- end-user-doc --> | ||
106 | * @generated | ||
107 | */ | ||
108 | public void setTarget(Constant newTarget) { | ||
109 | if (newTarget != target) { | ||
110 | NotificationChain msgs = null; | ||
111 | if (target != null) | ||
112 | msgs = ((InternalEObject)target).eInverseRemove(this, LogiclanguagePackage.CONSTANT__ANNOTATIONS, Constant.class, msgs); | ||
113 | if (newTarget != null) | ||
114 | msgs = ((InternalEObject)newTarget).eInverseAdd(this, LogiclanguagePackage.CONSTANT__ANNOTATIONS, Constant.class, msgs); | ||
115 | msgs = basicSetTarget(newTarget, msgs); | ||
116 | if (msgs != null) msgs.dispatch(); | ||
117 | } | ||
118 | else if (eNotificationRequired()) | ||
119 | eNotify(new ENotificationImpl(this, Notification.SET, LogicproblemPackage.CONSTANT_ANNOTATION__TARGET, newTarget, newTarget)); | ||
120 | } | ||
121 | |||
122 | /** | ||
123 | * <!-- begin-user-doc --> | ||
124 | * <!-- end-user-doc --> | ||
125 | * @generated | ||
126 | */ | ||
127 | @Override | ||
128 | public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
129 | switch (featureID) { | ||
130 | case LogicproblemPackage.CONSTANT_ANNOTATION__TARGET: | ||
131 | if (target != null) | ||
132 | msgs = ((InternalEObject)target).eInverseRemove(this, LogiclanguagePackage.CONSTANT__ANNOTATIONS, Constant.class, msgs); | ||
133 | return basicSetTarget((Constant)otherEnd, msgs); | ||
134 | } | ||
135 | return super.eInverseAdd(otherEnd, featureID, msgs); | ||
136 | } | ||
137 | |||
138 | /** | ||
139 | * <!-- begin-user-doc --> | ||
140 | * <!-- end-user-doc --> | ||
141 | * @generated | ||
142 | */ | ||
143 | @Override | ||
144 | public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { | ||
145 | switch (featureID) { | ||
146 | case LogicproblemPackage.CONSTANT_ANNOTATION__TARGET: | ||
147 | return basicSetTarget(null, msgs); | ||
148 | } | ||
149 | return super.eInverseRemove(otherEnd, featureID, msgs); | ||
150 | } | ||
151 | |||
152 | /** | ||
153 | * <!-- begin-user-doc --> | ||
154 | * <!-- end-user-doc --> | ||
155 | * @generated | ||
156 | */ | ||
157 | @Override | ||
158 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
159 | switch (featureID) { | ||
160 | case LogicproblemPackage.CONSTANT_ANNOTATION__TARGET: | ||
161 | if (resolve) return getTarget(); | ||
162 | return basicGetTarget(); | ||
163 | } | ||
164 | return super.eGet(featureID, resolve, coreType); | ||
165 | } | ||
166 | |||
167 | /** | ||
168 | * <!-- begin-user-doc --> | ||
169 | * <!-- end-user-doc --> | ||
170 | * @generated | ||
171 | */ | ||
172 | @Override | ||
173 | public void eSet(int featureID, Object newValue) { | ||
174 | switch (featureID) { | ||
175 | case LogicproblemPackage.CONSTANT_ANNOTATION__TARGET: | ||
176 | setTarget((Constant)newValue); | ||
177 | return; | ||
178 | } | ||
179 | super.eSet(featureID, newValue); | ||
180 | } | ||
181 | |||
182 | /** | ||
183 | * <!-- begin-user-doc --> | ||
184 | * <!-- end-user-doc --> | ||
185 | * @generated | ||
186 | */ | ||
187 | @Override | ||
188 | public void eUnset(int featureID) { | ||
189 | switch (featureID) { | ||
190 | case LogicproblemPackage.CONSTANT_ANNOTATION__TARGET: | ||
191 | setTarget((Constant)null); | ||
192 | return; | ||
193 | } | ||
194 | super.eUnset(featureID); | ||
195 | } | ||
196 | |||
197 | /** | ||
198 | * <!-- begin-user-doc --> | ||
199 | * <!-- end-user-doc --> | ||
200 | * @generated | ||
201 | */ | ||
202 | @Override | ||
203 | public boolean eIsSet(int featureID) { | ||
204 | switch (featureID) { | ||
205 | case LogicproblemPackage.CONSTANT_ANNOTATION__TARGET: | ||
206 | return target != null; | ||
207 | } | ||
208 | return super.eIsSet(featureID); | ||
209 | } | ||
210 | |||
211 | } //ConstantAnnotationImpl | ||