void setSourcepath(Path src) { if (sourcePath == null) { sourcePath = src; } else { sourcePath.append(src); } } /** * Create a path to be configured with the locations of the source * files. * * @return a new Path instance to be configured by the Ant core. */ public Path createSourcepath() { if (sourcePath == null) { sourcePath = new Path(getProject()); } return sourcePath.createPath();
void setClasspath(Path cp) { if (classpath == null) { classpath = cp; } else { classpath.append(cp); } } /** * Adds a path to the classpath. * @return a classpath to be configured. */ public Path createClasspath() { if (classpath == null) { classpath = new Path(getProject()); } return classpath.createPath();
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/WhichResource.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void setSourcepath(Path src) {
1
void setClasspath(Path cp) {
2
        if (sourcePath == null) {
2
        if (classpath == null) {
3
            sourcePath = src;
3
            classpath = cp;
4
        } else {
4
        } else {
5
            sourcePath.append(src);
5
            classpath.append(cp);
6
        }
6
        }
7
    }
7
    }
8
    /**
8
    /**
9
     * Create a path to be configured with the locations of the source
9
     * Adds a path to 
10
     * files.
11
     *
12
     * @return a new Path instance to be configured by the Ant core
10
the classpath.
13
.
11
     * @return a classpath to be configured.
14
     */
12
     */
15
    public Path createSourcepath() {
13
    public Path createClasspath() {
16
        if (sourcePath == null) {
14
        if (classpath == null) {
17
            sourcePath = new Path(getProject());
15
            classpath = new Path(getProject());
18
        }
16
        }
19
        return sourcePath.createPath();
17
        return classpath.createPath();
20
    
18
    
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 location
Number of node comparisons0