while (e.hasMoreElements()) {
String key = (String) e.nextElement();
Attribute attribute = getAttribute(key);
cloned.storeAttribute(new Attribute(attribute.getName(),
attribute.getValue()));
}
for (Enumeration e = genericJar.entries(); e.hasMoreElements();) {
JarEntry je = (JarEntry) e.nextElement();
genericEntries.put(je.getName().replace('\\', '/'), je);
}
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Manifest.java
|
|
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/ejb/WebsphereDeploymentTool.java
|
Method name: Object clone()
|
|
Method name: boolean isRebuildRequired(File, File)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 3
|
|
1 | while (e.hasMoreElements()) {↵ | | 1 | for (Enumeration e = genericJar.entries(); e.hasMoreElements();) {↵
|
2 | String key = (String) e.nextElement();↵ | | 2 | JarEntry je = (JarEntry) e.nextElement();↵
|
|
3 | Attribute attribute = getAttribute(key);↵ | | 3 | ↵
|
4 | cloned.storeAttribute(new Attribute(attribute.getName(),↵ | | |
|
5 | attribute.getValue()));↵ | | |
|
| | | 4 | genericEntries.put(je.getName().replace('\\', '/'), je);↵
|
6 | } | | 5 | }
|
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 |