if (recurse) { NodeList recmatches = listChildNodes(child, filter, recurse); final int reclength = recmatches.getLength(); for (int j = 0; j < reclength; j++) { matches.addElement(recmatches.item(i)); } }
for (int i = 0; i < instructions.size(); i++) { ImageOperation instr = ((ImageOperation) instructions.elementAt(i)); if (instr instanceof DrawOperation) { PlanarImage image = null; // If this TransformOperation has DrawOperation children // then Rotate the first child and return. performScale(image); return image; } }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/junit/DOMUtil.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/types/optional/image/Scale.java
Method name: NodeList listChildNodes(Node, NodeFilter, boolean) Method name: PlanarImage executeDrawOperation()
Number of AST nodes: 5 Number of AST nodes: 6
1
if (recurse) {
2
                    NodeList recmatches = listChildNodes(child, filter, recurse);
3
                    final int reclength = recmatches.getLength();
4
                    for (int j = 0; j < reclength; j++) {
5
                        matches.addElement(recmatches.item(i)
1
for (int i = 0; i < instructions.size(); i++) {
2
            ImageOperation instr = ((ImageOperation) instructions.elementAt(i));
3
            if (instr instanceof DrawOperation) {
4
                PlanarImage image = null;
5
                // If this TransformOperation has DrawOperation children
6
                // then Rotate the first child and return.
6
);
7
                performScale(image);
7
                    }
8
                return image;
8
        
9
            }
9
        }
10
        }
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones locationClones are in different classes
Number of node comparisons1