File path: /emf-2.4.1/src/org/eclipse/emf/ecore/impl/EStructuralFeatureImpl.java | File path: /emf-2.4.1/src/org/eclipse/emf/ecore/impl/EStructuralFeatureImpl.java | |||
Method name: void dynamicSet(InternalEObject, EStructuralFeature.Internal.DynamicValueHolder, int, Object)
|
Method name: void dynamicUnset(InternalEObject, EStructuralFeature.Internal.DynamicValueHolder, int)
|
|||
Number of AST nodes: 8 | Number of AST nodes: 8 | |||
1 | if (owner.eNotificationRequired())↵ | 1 | if (owner.eNotificationRequired())↵ | |
2 | {↵ | 2 | {↵ | |
3 | Notification notification = ↵ | 3 | Notification notification = ↵ | |
4 | new ENotificationImpl↵ | 4 | new ENotificationImpl↵ | |
5 | (owner, ↵ | 5 | (owner, ↵ | |
6 | Notification.SET, ↵ | 6 | isUnsettable() ? Notification.UNSET : Notification.SET, ↵ | |
7 | feature,↵ | 7 | feature,↵ | |
8 | oldValue, ↵ | 8 | oldValue, ↵ | |
9 | newValue,↵ | 9 | n↵ | |
10 | isUnsettable() && !oldIsSet);↵ | 10 | ull);↵ | |
11 | if (notifications == null)↵ | 11 | if (notifications == null)↵ | |
12 | {↵ | 12 | {↵ | |
13 | owner.eNotify(notification);↵ | 13 | owner.eNotify(notification);↵ | |
14 | }↵ | 14 | }↵ | |
15 | else↵ | 15 | else↵ | |
16 | {↵ | 16 | {↵ | |
17 | notifications.add(notification);↵ | 17 | notifications.add(notification);↵ | |
18 | notifications.dispatch();↵ | 18 | notifications.dispatch();↵ | |
19 | }↵ | 19 | }↵ | |
20 | }↵ | 20 | }↵ | |
21 | else if (notifications != null)↵ | 21 | else if (notifications != null)↵ | |
22 | {↵ | 22 | {↵ | |
23 | notifications.dispatch();↵ | 23 | notifications.dispatch();↵ | |
24 | } | 24 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.3 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 24 |
Number of mapped statements | 8 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 2.2 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
23 | if (owner.eNotificationRequired()) | 12 | if (owner.eNotificationRequired()) | |||||||||||
24 | Notification notification = new ENotificationImpl(owner, Notification.SET, feature, oldValue, newValue, isUnsettable() && !oldIsSet); |
| 13 | Notification notification = new ENotificationImpl(owner, isUnsettable() ? Notification.UNSET : Notification.SET, feature, oldValue, null); | ||||||||||
25 | if (notifications == null) | 14 | if (notifications == null) | |||||||||||
26 | owner.eNotify(notification); | 15 | owner.eNotify(notification); | |||||||||||
else | else | |||||||||||||
27 | notifications.add(notification); | 16 | notifications.add(notification); | |||||||||||
28 | notifications.dispatch(); | 17 | notifications.dispatch(); | |||||||||||
29 | else if (notifications != null) | 18 | else if (notifications != null) | |||||||||||
30 | notifications.dispatch(); | 19 | notifications.dispatch(); |
Row | Violation |
---|