for (Enumeration e = fileProperties.keys(); e.hasMoreElements();) {
String key = (String) e.nextElement();
String value = fileProperties.getProperty(key);
properties.put(key, project.replaceProperties(value));
}
for (Iterator i = filesList.iterator(); i.hasNext();) {
File f = (File) i.next();
File newFile = new File(destDir, f.getName());
if (newFile.exists()) {
filesToRemove.add(f);
}
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/listener/MailLogger.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/image/Image.java
|
Method name: void buildFinished(BuildEvent)
|
|
Method name: void execute()
|
Number of AST nodes: 4
|
|
Number of AST nodes: 5
|
|
1 | for (Enumeration e = fileProperties.keys(); e.hasMoreElements();) {↵ | | 1 | for (Iterator i = filesList.iterator(); i.hasNext();) {↵
|
2 | String key = (String) e.nextElement();↵ | | 2 | File f = (File) i.next();↵
|
3 | String value = fileProperties.getProperty(key);↵ | | 3 | ↵
|
4 | properties.put(key, project.replaceProperties(value));↵ | | |
|
| | | 4 | File newFile = new File(destDir, f.getName());↵
|
| | | 5 | if (newFile.exists()) {↵
|
| | | 6 | filesToRemove.add(f);↵
|
| | | 7 | }↵
|
5 | } | | 8 | }
|
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.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 1 |