if (getJars && element.isDirectory()) {
// add any jars in the directory
URL[] dirURLs = Locator.getLocationURLs(element);
for (int j = 0; j < dirURLs.length; ++j) {
libPathURLs.add(dirURLs[j]);
}
}
if (!fileset.isEmpty()) {
final Extension[] extensions = getExtensions(project,
fileset);
for (int i = 0; i < extensions.length; i++) {
libraries.add(extensions[ i ]);
}
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/launch/Launcher.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/extension/ExtensionUtil.java
|
Method name: void addPath(String, boolean, List)
|
|
Method name: void extractExtensions(Project, List, List)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | if (getJars && element.isDirectory()) {↵ | | 1 | if (!fileset.isEmpty()) {↵
|
2 | // add any jars in the directory↵ | | 2 | ↵
|
3 | URL[] dirURLs = Locator.getLocationURLs(element);↵ | | |
|
4 | ↵ | | 3 | final Extension[] extensions = getExtensions(project,↵
|
| | | 4 | fileset);↵
|
5 | for (int j = 0; j < dirURLs.length; ++j) {↵ | | 5 | for (int i = 0; i < extensions.length; i++) {↵
|
6 | libPathURLs.add(dirURLs[j]);↵ | | 6 | libraries.add(extensions[ i ]);↵
|
7 | }↵ | | 7 | ↵
|
8 | ↵ | | 8 | }↵
|
9 | } | | 9 | }
|
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.2 |
Clones location | Clones are in different classes |
Number of node comparisons | 1 |