for (int i = 0, size = delegateSize(); i < size; ++i)
{
Entry entry = delegateGet(i);
if (validator.isValid(entry.getEStructuralFeature()))
{
if (entry.getValue() == null)
{
return result;
}
++result;
}
}
for (int i = 0, size = delegateSize(); i < size; ++i)
{
Entry entry = delegateGet(i);
if (validator.isValid(entry.getEStructuralFeature()))
{
if (entry.equals(object))
{
match = entry;
break;
}
++count;
}
}
Clone fragments detected by clone detection tool
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/DelegatingFeatureMap.java
|
Method name: int indexOf(EStructuralFeature, Object, boolean)
|
|
Method name: NotificationChain basicRemove(EStructuralFeature, Object, NotificationChain)
|
Number of AST nodes: 6
|
|
Number of AST nodes: 7
|
|
1 | for (int i = 0, size = delegateSize(); i < size; ++i)↵ | | 1 | for (int i = 0, size = delegateSize(); i < size; ++i)↵
|
2 | {↵ | | 2 | {↵
|
3 | Entry entry = delegateGet(i);↵ | | 3 | Entry entry = delegateGet(i);↵
|
4 | if (validator.isValid(entry.getEStructuralFeature()))↵ | | 4 | if (validator.isValid(entry.getEStructuralFeature()))↵
|
5 | {↵ | | 5 | {↵
|
6 | if (entry.getValue() == null)↵ | | 6 | if (entry.equals(object))↵
|
7 | {↵ | | 7 | {↵
|
8 | return result↵ | | 8 | match = entry;↵
|
9 | ;↵ | | 9 | break;↵
|
10 | }↵ | | 10 | }↵
|
11 | ++result;↵ | | 11 | ++count;↵
|
12 | }↵ | | 12 | }↵
|
13 | } | | 13 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1 |
Clones location | Clones are declared in the same class |
Number of node comparisons | 1 |