diff options
Diffstat (limited to 'Domains/github-graph/ecore-gen/github/impl/IssueEventImpl.java')
-rw-r--r-- | Domains/github-graph/ecore-gen/github/impl/IssueEventImpl.java | 344 |
1 files changed, 344 insertions, 0 deletions
diff --git a/Domains/github-graph/ecore-gen/github/impl/IssueEventImpl.java b/Domains/github-graph/ecore-gen/github/impl/IssueEventImpl.java new file mode 100644 index 00000000..6af771c5 --- /dev/null +++ b/Domains/github-graph/ecore-gen/github/impl/IssueEventImpl.java | |||
@@ -0,0 +1,344 @@ | |||
1 | /** | ||
2 | */ | ||
3 | package github.impl; | ||
4 | |||
5 | import github.Action; | ||
6 | import github.GithubPackage; | ||
7 | import github.IssueEvent; | ||
8 | import github.User; | ||
9 | |||
10 | import java.util.Date; | ||
11 | |||
12 | import org.eclipse.emf.common.notify.Notification; | ||
13 | |||
14 | import org.eclipse.emf.ecore.EClass; | ||
15 | import org.eclipse.emf.ecore.InternalEObject; | ||
16 | |||
17 | import org.eclipse.emf.ecore.impl.ENotificationImpl; | ||
18 | import org.eclipse.emf.ecore.impl.MinimalEObjectImpl; | ||
19 | |||
20 | /** | ||
21 | * <!-- begin-user-doc --> | ||
22 | * An implementation of the model object '<em><b>Issue Event</b></em>'. | ||
23 | * <!-- end-user-doc --> | ||
24 | * <p> | ||
25 | * The following features are implemented: | ||
26 | * </p> | ||
27 | * <ul> | ||
28 | * <li>{@link github.impl.IssueEventImpl#getUser <em>User</em>}</li> | ||
29 | * <li>{@link github.impl.IssueEventImpl#getAction <em>Action</em>}</li> | ||
30 | * <li>{@link github.impl.IssueEventImpl#getCreated_at <em>Created at</em>}</li> | ||
31 | * <li>{@link github.impl.IssueEventImpl#getActor_url <em>Actor url</em>}</li> | ||
32 | * </ul> | ||
33 | * | ||
34 | * @generated | ||
35 | */ | ||
36 | public class IssueEventImpl extends MinimalEObjectImpl.Container implements IssueEvent { | ||
37 | /** | ||
38 | * The cached value of the '{@link #getUser() <em>User</em>}' reference. | ||
39 | * <!-- begin-user-doc --> | ||
40 | * <!-- end-user-doc --> | ||
41 | * @see #getUser() | ||
42 | * @generated | ||
43 | * @ordered | ||
44 | */ | ||
45 | protected User user; | ||
46 | |||
47 | /** | ||
48 | * The default value of the '{@link #getAction() <em>Action</em>}' attribute. | ||
49 | * <!-- begin-user-doc --> | ||
50 | * <!-- end-user-doc --> | ||
51 | * @see #getAction() | ||
52 | * @generated | ||
53 | * @ordered | ||
54 | */ | ||
55 | protected static final Action ACTION_EDEFAULT = Action.SUBSCRIBED; | ||
56 | |||
57 | /** | ||
58 | * The cached value of the '{@link #getAction() <em>Action</em>}' attribute. | ||
59 | * <!-- begin-user-doc --> | ||
60 | * <!-- end-user-doc --> | ||
61 | * @see #getAction() | ||
62 | * @generated | ||
63 | * @ordered | ||
64 | */ | ||
65 | protected Action action = ACTION_EDEFAULT; | ||
66 | |||
67 | /** | ||
68 | * The default value of the '{@link #getCreated_at() <em>Created at</em>}' attribute. | ||
69 | * <!-- begin-user-doc --> | ||
70 | * <!-- end-user-doc --> | ||
71 | * @see #getCreated_at() | ||
72 | * @generated | ||
73 | * @ordered | ||
74 | */ | ||
75 | protected static final Date CREATED_AT_EDEFAULT = null; | ||
76 | |||
77 | /** | ||
78 | * The cached value of the '{@link #getCreated_at() <em>Created at</em>}' attribute. | ||
79 | * <!-- begin-user-doc --> | ||
80 | * <!-- end-user-doc --> | ||
81 | * @see #getCreated_at() | ||
82 | * @generated | ||
83 | * @ordered | ||
84 | */ | ||
85 | protected Date created_at = CREATED_AT_EDEFAULT; | ||
86 | |||
87 | /** | ||
88 | * The default value of the '{@link #getActor_url() <em>Actor url</em>}' attribute. | ||
89 | * <!-- begin-user-doc --> | ||
90 | * <!-- end-user-doc --> | ||
91 | * @see #getActor_url() | ||
92 | * @generated | ||
93 | * @ordered | ||
94 | */ | ||
95 | protected static final String ACTOR_URL_EDEFAULT = null; | ||
96 | |||
97 | /** | ||
98 | * The cached value of the '{@link #getActor_url() <em>Actor url</em>}' attribute. | ||
99 | * <!-- begin-user-doc --> | ||
100 | * <!-- end-user-doc --> | ||
101 | * @see #getActor_url() | ||
102 | * @generated | ||
103 | * @ordered | ||
104 | */ | ||
105 | protected String actor_url = ACTOR_URL_EDEFAULT; | ||
106 | |||
107 | /** | ||
108 | * <!-- begin-user-doc --> | ||
109 | * <!-- end-user-doc --> | ||
110 | * @generated | ||
111 | */ | ||
112 | protected IssueEventImpl() { | ||
113 | super(); | ||
114 | } | ||
115 | |||
116 | /** | ||
117 | * <!-- begin-user-doc --> | ||
118 | * <!-- end-user-doc --> | ||
119 | * @generated | ||
120 | */ | ||
121 | @Override | ||
122 | protected EClass eStaticClass() { | ||
123 | return GithubPackage.Literals.ISSUE_EVENT; | ||
124 | } | ||
125 | |||
126 | /** | ||
127 | * <!-- begin-user-doc --> | ||
128 | * <!-- end-user-doc --> | ||
129 | * @generated | ||
130 | */ | ||
131 | @Override | ||
132 | public User getUser() { | ||
133 | if (user != null && user.eIsProxy()) { | ||
134 | InternalEObject oldUser = (InternalEObject)user; | ||
135 | user = (User)eResolveProxy(oldUser); | ||
136 | if (user != oldUser) { | ||
137 | if (eNotificationRequired()) | ||
138 | eNotify(new ENotificationImpl(this, Notification.RESOLVE, GithubPackage.ISSUE_EVENT__USER, oldUser, user)); | ||
139 | } | ||
140 | } | ||
141 | return user; | ||
142 | } | ||
143 | |||
144 | /** | ||
145 | * <!-- begin-user-doc --> | ||
146 | * <!-- end-user-doc --> | ||
147 | * @generated | ||
148 | */ | ||
149 | public User basicGetUser() { | ||
150 | return user; | ||
151 | } | ||
152 | |||
153 | /** | ||
154 | * <!-- begin-user-doc --> | ||
155 | * <!-- end-user-doc --> | ||
156 | * @generated | ||
157 | */ | ||
158 | @Override | ||
159 | public void setUser(User newUser) { | ||
160 | User oldUser = user; | ||
161 | user = newUser; | ||
162 | if (eNotificationRequired()) | ||
163 | eNotify(new ENotificationImpl(this, Notification.SET, GithubPackage.ISSUE_EVENT__USER, oldUser, user)); | ||
164 | } | ||
165 | |||
166 | /** | ||
167 | * <!-- begin-user-doc --> | ||
168 | * <!-- end-user-doc --> | ||
169 | * @generated | ||
170 | */ | ||
171 | @Override | ||
172 | public Action getAction() { | ||
173 | return action; | ||
174 | } | ||
175 | |||
176 | /** | ||
177 | * <!-- begin-user-doc --> | ||
178 | * <!-- end-user-doc --> | ||
179 | * @generated | ||
180 | */ | ||
181 | @Override | ||
182 | public void setAction(Action newAction) { | ||
183 | Action oldAction = action; | ||
184 | action = newAction == null ? ACTION_EDEFAULT : newAction; | ||
185 | if (eNotificationRequired()) | ||
186 | eNotify(new ENotificationImpl(this, Notification.SET, GithubPackage.ISSUE_EVENT__ACTION, oldAction, action)); | ||
187 | } | ||
188 | |||
189 | /** | ||
190 | * <!-- begin-user-doc --> | ||
191 | * <!-- end-user-doc --> | ||
192 | * @generated | ||
193 | */ | ||
194 | @Override | ||
195 | public Date getCreated_at() { | ||
196 | return created_at; | ||
197 | } | ||
198 | |||
199 | /** | ||
200 | * <!-- begin-user-doc --> | ||
201 | * <!-- end-user-doc --> | ||
202 | * @generated | ||
203 | */ | ||
204 | @Override | ||
205 | public void setCreated_at(Date newCreated_at) { | ||
206 | Date oldCreated_at = created_at; | ||
207 | created_at = newCreated_at; | ||
208 | if (eNotificationRequired()) | ||
209 | eNotify(new ENotificationImpl(this, Notification.SET, GithubPackage.ISSUE_EVENT__CREATED_AT, oldCreated_at, created_at)); | ||
210 | } | ||
211 | |||
212 | /** | ||
213 | * <!-- begin-user-doc --> | ||
214 | * <!-- end-user-doc --> | ||
215 | * @generated | ||
216 | */ | ||
217 | @Override | ||
218 | public String getActor_url() { | ||
219 | return actor_url; | ||
220 | } | ||
221 | |||
222 | /** | ||
223 | * <!-- begin-user-doc --> | ||
224 | * <!-- end-user-doc --> | ||
225 | * @generated | ||
226 | */ | ||
227 | @Override | ||
228 | public void setActor_url(String newActor_url) { | ||
229 | String oldActor_url = actor_url; | ||
230 | actor_url = newActor_url; | ||
231 | if (eNotificationRequired()) | ||
232 | eNotify(new ENotificationImpl(this, Notification.SET, GithubPackage.ISSUE_EVENT__ACTOR_URL, oldActor_url, actor_url)); | ||
233 | } | ||
234 | |||
235 | /** | ||
236 | * <!-- begin-user-doc --> | ||
237 | * <!-- end-user-doc --> | ||
238 | * @generated | ||
239 | */ | ||
240 | @Override | ||
241 | public Object eGet(int featureID, boolean resolve, boolean coreType) { | ||
242 | switch (featureID) { | ||
243 | case GithubPackage.ISSUE_EVENT__USER: | ||
244 | if (resolve) return getUser(); | ||
245 | return basicGetUser(); | ||
246 | case GithubPackage.ISSUE_EVENT__ACTION: | ||
247 | return getAction(); | ||
248 | case GithubPackage.ISSUE_EVENT__CREATED_AT: | ||
249 | return getCreated_at(); | ||
250 | case GithubPackage.ISSUE_EVENT__ACTOR_URL: | ||
251 | return getActor_url(); | ||
252 | } | ||
253 | return super.eGet(featureID, resolve, coreType); | ||
254 | } | ||
255 | |||
256 | /** | ||
257 | * <!-- begin-user-doc --> | ||
258 | * <!-- end-user-doc --> | ||
259 | * @generated | ||
260 | */ | ||
261 | @Override | ||
262 | public void eSet(int featureID, Object newValue) { | ||
263 | switch (featureID) { | ||
264 | case GithubPackage.ISSUE_EVENT__USER: | ||
265 | setUser((User)newValue); | ||
266 | return; | ||
267 | case GithubPackage.ISSUE_EVENT__ACTION: | ||
268 | setAction((Action)newValue); | ||
269 | return; | ||
270 | case GithubPackage.ISSUE_EVENT__CREATED_AT: | ||
271 | setCreated_at((Date)newValue); | ||
272 | return; | ||
273 | case GithubPackage.ISSUE_EVENT__ACTOR_URL: | ||
274 | setActor_url((String)newValue); | ||
275 | return; | ||
276 | } | ||
277 | super.eSet(featureID, newValue); | ||
278 | } | ||
279 | |||
280 | /** | ||
281 | * <!-- begin-user-doc --> | ||
282 | * <!-- end-user-doc --> | ||
283 | * @generated | ||
284 | */ | ||
285 | @Override | ||
286 | public void eUnset(int featureID) { | ||
287 | switch (featureID) { | ||
288 | case GithubPackage.ISSUE_EVENT__USER: | ||
289 | setUser((User)null); | ||
290 | return; | ||
291 | case GithubPackage.ISSUE_EVENT__ACTION: | ||
292 | setAction(ACTION_EDEFAULT); | ||
293 | return; | ||
294 | case GithubPackage.ISSUE_EVENT__CREATED_AT: | ||
295 | setCreated_at(CREATED_AT_EDEFAULT); | ||
296 | return; | ||
297 | case GithubPackage.ISSUE_EVENT__ACTOR_URL: | ||
298 | setActor_url(ACTOR_URL_EDEFAULT); | ||
299 | return; | ||
300 | } | ||
301 | super.eUnset(featureID); | ||
302 | } | ||
303 | |||
304 | /** | ||
305 | * <!-- begin-user-doc --> | ||
306 | * <!-- end-user-doc --> | ||
307 | * @generated | ||
308 | */ | ||
309 | @Override | ||
310 | public boolean eIsSet(int featureID) { | ||
311 | switch (featureID) { | ||
312 | case GithubPackage.ISSUE_EVENT__USER: | ||
313 | return user != null; | ||
314 | case GithubPackage.ISSUE_EVENT__ACTION: | ||
315 | return action != ACTION_EDEFAULT; | ||
316 | case GithubPackage.ISSUE_EVENT__CREATED_AT: | ||
317 | return CREATED_AT_EDEFAULT == null ? created_at != null : !CREATED_AT_EDEFAULT.equals(created_at); | ||
318 | case GithubPackage.ISSUE_EVENT__ACTOR_URL: | ||
319 | return ACTOR_URL_EDEFAULT == null ? actor_url != null : !ACTOR_URL_EDEFAULT.equals(actor_url); | ||
320 | } | ||
321 | return super.eIsSet(featureID); | ||
322 | } | ||
323 | |||
324 | /** | ||
325 | * <!-- begin-user-doc --> | ||
326 | * <!-- end-user-doc --> | ||
327 | * @generated | ||
328 | */ | ||
329 | @Override | ||
330 | public String toString() { | ||
331 | if (eIsProxy()) return super.toString(); | ||
332 | |||
333 | StringBuilder result = new StringBuilder(super.toString()); | ||
334 | result.append(" (action: "); | ||
335 | result.append(action); | ||
336 | result.append(", created_at: "); | ||
337 | result.append(created_at); | ||
338 | result.append(", actor_url: "); | ||
339 | result.append(actor_url); | ||
340 | result.append(')'); | ||
341 | return result.toString(); | ||
342 | } | ||
343 | |||
344 | } //IssueEventImpl | ||