File path: /emf-2.4.1/src/org/eclipse/emf/ecore/util/DelegatingFeatureMap.java | File path: /emf-2.4.1/src/org/eclipse/emf/ecore/util/BasicFeatureMap.java | |||
Method name: Object setUnique(EStructuralFeature, int, Object)
|
Method name: Object set(EStructuralFeature, int, Object)
|
|||
Number of AST nodes: 5 | Number of AST nodes: 5 | |||
1 | Entry entry = delegateGet(i);↵ | 1 | Entry entry = entries[i];↵ | |
2 | if (validator.isValid(entry.getEStructuralFeature()))↵ | 2 | if (validator.isValid(entry.getEStructuralFeature()))↵ | |
3 | {↵ | 3 | {↵ | |
4 | if (count == index)↵ | 4 | if (count == index)↵ | |
5 | {↵ | 5 | {↵ | |
6 | return setUnique(i, FeatureMapUtil.isFeatureMap(feature) ? (Entry)object : createEntry(feature, object));↵ | 6 | return doSet(i, FeatureMapUtil.isFeatureMap(feature) ? (Entry)object : createEntry(feature, object));↵ | |
7 | }↵ | 7 | }↵ | |
8 | ++count;↵ | 8 | ++count;↵ | |
9 | } | 9 |
| |
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 in different classes having the same super class |
Number of node comparisons | 10 |
Number of mapped statements | 5 |
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) | 1.5 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
5 | Entry entry = delegateGet(i); |
| 10 | Entry entry = entries[i]; | ||||||||||
6 | if (validator.isValid(entry.getEStructuralFeature())) | 11 | if (validator.isValid(entry.getEStructuralFeature())) | |||||||||||
7 | if (count == index) | 12 | if (count == index) | |||||||||||
8 | return setUnique(i, FeatureMapUtil.isFeatureMap(feature) ? (Entry)object : createEntry(feature, object)); |
| 13 | return doSet(i, FeatureMapUtil.isFeatureMap(feature) ? (Entry)object : createEntry(feature, object)); | ||||||||||
9 | ++count; | 14 | ++count; |
Row | Violation |
---|