RuntimeConfigurable r = (RuntimeConfigurable) e.nextElement();
UnknownElement ueChild = (UnknownElement) r.getProxy();
UnknownElement copyChild = ueChild.copy(newProject);
copyRC.addChild(copyChild.getWrapper());
ret.addChild(copyChild);
for (Enumeration e = fileProperties.keys(); e.hasMoreElements();) {
String key = (String) e.nextElement();
String value = fileProperties.getProperty(key);
properties.put(key, project.replaceProperties(value));
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/UnknownElement.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/listener/MailLogger.java
|
Method name: UnknownElement copy(Project)
|
|
Method name: void buildFinished(BuildEvent)
|
Number of AST nodes: 5
|
|
Number of AST nodes: 4
|
|
1 | RuntimeConfigurable r = (RuntimeConfigurable) e.nextElement();↵ | | 1 | for (Enumeration e = fileProperties.keys(); e.hasMoreElements();) {↵
|
2 | UnknownElement ueChild = (UnknownElement) r.getProxy();↵ | | 2 | ↵
|
3 | UnknownElement copyChild = ueChild.copy(newProject);↵ | | |
|
4 | copyRC.addChild(copyChild.getWrapper());↵ | | |
|
5 | ret.addChild(copyChild); | | 3 | String key = (String) e.nextElement();↵
|
| | | 4 | String value = fileProperties.getProperty(key);↵
|
| | | 5 | properties.put(key, project.replaceProperties(value));↵
|
| | | 6 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 15 |
-
{Non-refactorable}
Mapping Summary
Number of mapped statements | 0 |
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) | 0.0 |
Clone type | Unknown type |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
Precondition Violations (0)
Row |
Violation |