if (tagletInfo.getPath() != null) { Path tagletPath = tagletInfo.getPath() .concatSystemClasspath("ignore"); if (tagletPath.size() != 0) { toExecute.createArgument() .setValue("-tagletpath"); toExecute.createArgument().setPath(tagletPath); } }
if (doclet.getPath() != null) { Path docletPath = doclet.getPath().concatSystemClasspath("ignore"); if (docletPath.size() != 0) { toExecute.createArgument().setValue("-docletpath"); toExecute.createArgument().setPath(docletPath); } }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Javadoc.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/Javadoc.java
Method name: void execute() Method name: void execute()
Number of AST nodes: 5 Number of AST nodes: 5
1
if (tagletInfo.getPath() != null) {
1
if (doclet.getPath() != null) {
2
                        Path tagletPath = tagletInfo.getPath()
2
                    Path docletPath
3
                            .concatSystemClasspath("ignore");
3
                        = doclet.getPath().concatSystemClasspath("ignore");
4
                        if (tagletPath.size() != 0) {
4
                    if (docletPath.size() != 0) {
5
                            toExecute.createArgument()
5
                        toExecute.createArgument()
6
                                .setValue("-tagletpath");
6
.setValue("-docletpath");
7
                            toExecute.createArgument().setPath(tagletPath);
7
                        toExecute.createArgument().setPath(docletPath);
8
                        }
8
                    
9
    
9
}
10
                }
10
                }
Summary
Number of common nesting structure subtrees1
Number of refactorable cases1
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.3
Clones locationClones are in the same method
Number of node comparisons14
  1. {Refactorable}
    Mapping Summary
    Number of mapped statements5
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)7.2
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    151
    if (tagletInfo.getPath() != null)
    151
    if (tagletInfo.getPath() != null)
    57
    if (doclet.getPath() != null)
    Differences
    Expression1Expression2Difference
    tagletInfodocletVARIABLE_NAME_MISMATCH
    org.apache.tools.ant.taskdefs.Javadoc.ExtensionInfoorg.apache.tools.ant.taskdefs.Javadoc.DocletInfoSUBCLASS_TYPE_MISMATCH
    57
    if (doclet.getPath() != null)
    152
    Path tagletPath = tagletInfo.getPath().concatSystemClasspath("ignore");
    152
    Path tagletPath = tagletInfo.getPath().concatSystemClasspath("ignore");
    58
    Path docletPath = doclet.getPath().concatSystemClasspath("ignore");
    Differences
    Expression1Expression2Difference
    tagletPathdocletPathVARIABLE_NAME_MISMATCH
    tagletInfodocletVARIABLE_NAME_MISMATCH
    org.apache.tools.ant.taskdefs.Javadoc.ExtensionInfoorg.apache.tools.ant.taskdefs.Javadoc.DocletInfoSUBCLASS_TYPE_MISMATCH
    58
    Path docletPath = doclet.getPath().concatSystemClasspath("ignore");
    153
    if (tagletPath.size() != 0)
    153
    if (tagletPath.size() != 0)
    59
    if (docletPath.size() != 0)
    Differences
    Expression1Expression2Difference
    tagletPathdocletPathVARIABLE_NAME_MISMATCH
    59
    if (docletPath.size() != 0)
    154
    toExecute.createArgument().setValue("-tagletpath");
    154
    toExecute.createArgument().setValue("-tagletpath");
    60
    toExecute.createArgument().setValue("-docletpath");
    Differences
    Expression1Expression2Difference
    "-tagletpath""-docletpath"LITERAL_VALUE_MISMATCH
    60
    toExecute.createArgument().setValue("-docletpath");
    155
    toExecute.createArgument().setPath(tagletPath);
    155
    toExecute.createArgument().setPath(tagletPath);
    61
    toExecute.createArgument().setPath(docletPath);
    Differences
    Expression1Expression2Difference
    tagletPathdocletPathVARIABLE_NAME_MISMATCH
    61
    toExecute.createArgument().setPath(docletPath);
    Precondition Violations (0)
    Row Violation