for (int i = 0; i < excludes.length; i++) {
String e = excludes[i];
if (e.endsWith("**") && SelectorUtils.matchPath(
e.substring(0, e.length() - 2), name, isCaseSensitive())) {
return true;
}
}
for (int i = 0; i < methods.length; i++) {
Method methodEntry = methods[i];
if (methodEntry.getName().equals(method)) {
return true;
}
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/DirectoryScanner.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/condition/HasMethod.java
|
Method name: boolean contentsExcluded(String)
|
|
Method name: boolean isMethodFound(Class)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | for (int i = 0; i < excludes.length; i++) {↵ | | 1 | for (int i = 0; i < methods.length; i++) {↵
|
2 | String e = excludes[i];↵ | | 2 | ↵
|
3 | if (e.endsWith("**") && SelectorUtils.matchPath(↵ | | |
|
4 | e.substring(0, e.length() - 2), name, isCaseSensitive()↵ | | 3 | Method methodEntry = methods[i];↵
|
5 | )) {↵ | | 4 | if (methodEntry.getName().equals(method)) {↵
|
6 | return true;↵ | | 5 | return true;↵
|
7 | }↵ | | 6 | }↵
|
8 | } | | 7 | }
|
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 in different classes |
Number of node comparisons | 1 |