try { listeners.addElement(args[i + 1]); i++; } catch (ArrayIndexOutOfBoundsException aioobe) { String msg = "You must specify a classname when " + "using the -listener argument"; throw new BuildException(msg); }
try { propertyFiles.addElement(args[i + 1]); i++; } catch (ArrayIndexOutOfBoundsException aioobe) { String msg = "You must specify a property filename when " + "using the -propertyfile argument"; throw new BuildException(msg); }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/Main.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/Main.java
Method name: void processArgs(String[]) Method name: void processArgs(String[])
Number of AST nodes: 3 Number of AST nodes: 3
1
try {
1
try {
2
                    listeners.addElement(args[i + 1]);
2
                    propertyFiles.addElement(args[i + 1]);
3
                    i++;
3
                    i++;
4
                } catch (ArrayIndexOutOfBoundsException aioobe) {
4
                } catch (ArrayIndexOutOfBoundsException aioobe) {
5
                    String msg = "You must specify a classname when "
5
                    String msg = "You must specify a property filename when "
6
                        + "using the -listener argument";
6
                        + "using the -propertyfile argument";
7
                    throw new BuildException(msg);
7
                    throw new BuildException(msg);
8
                }
8
                }
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.5
Clones locationClones are in the same method
Number of node comparisons11
  1. {Refactorable}
    Mapping Summary
    Number of mapped statements3
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)1.5
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    43
    try
    43
    try
    76
    try
    Differences
    Expression1Expression2Difference
    "You must specify a classname when ""You must specify a property filename when "LITERAL_VALUE_MISMATCH
    "using the -listener argument""using the -propertyfile argument"LITERAL_VALUE_MISMATCH
    76
    try
    44
    listeners.addElement(args[i + 1]);
    44
    listeners.addElement(args[i + 1]);
    77
    propertyFiles.addElement(args[i + 1]);
    Differences
    Expression1Expression2Difference
    listenerspropertyFilesVARIABLE_NAME_MISMATCH
    77
    propertyFiles.addElement(args[i + 1]);
    45
    i++;
    78
    i++;
    Precondition Violations (0)
    Row Violation