File path: /emf-2.4.1/src/org/eclipse/emf/common/notify/impl/NotifyingListImpl.java | File path: /emf-2.4.1/src/org/eclipse/emf/common/notify/impl/NotifyingListImpl.java | |||
Method name: boolean addAllUnique(int, Object[], int, int)
|
Method name: boolean addAllUnique(int, Collection extends E>)
|
|||
Number of AST nodes: 7 | Number of AST nodes: 7 | |||
1 | NotificationChain notifications = createNotificationChain(collectionSize);↵ | 1 | NotificationChain notifications = createNotificationChain(collectionSize);↵ | |
2 | int lastIndex = index + collectionSize;↵ | 2 | int lastIndex = index + collectionSize;↵ | |
3 | for (int i = index; i < lastIndex; ++i)↵ | 3 | for (int i = index; i < lastIndex; ++i)↵ | |
4 | { ↵ | 4 | { ↵ | |
5 | @SuppressWarnings("unchecked") E object = (E)data[i];↵ | 5 | @SuppressWarnings("unchecked") E object = (E)data[i];↵ | |
6 | notifications = inverseAdd(object, notifications);↵ | 6 | notifications = inverseAdd(object, notifications);↵ | |
7 | }↵ | 7 | }↵ | |
8 | if (notifications != null) notifications.dispatch(); | 8 |
| |
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.2 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 25 |
Number of mapped statements | 7 |
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) | 0.9 |
Clone type | Type 1 |
ID | Statement | ID | Statement | |
---|---|---|---|---|
30 | NotificationChain notifications = createNotificationChain(collectionSize); | 22 | NotificationChain notifications = createNotificationChain(collectionSize); | |
31 | int lastIndex = index + collectionSize; | 23 | int lastIndex = index + collectionSize; | |
32 | for (int i = index; i < lastIndex; ++i) | 24 | for (int i = index; i < lastIndex; ++i) | |
33 | @SuppressWarnings("unchecked") E object = (E)data[i]; | 25 | @SuppressWarnings("unchecked") E object = (E)data[i]; | |
34 | notifications = inverseAdd(object, notifications); | 26 | notifications = inverseAdd(object, notifications); | |
35 | if (notifications != null) | 27 | if (notifications != null) | |
36 | notifications.dispatch(); | 28 | notifications.dispatch(); |
Row | Violation |
---|