void setClasspath(Path src) { if (classpath == null) { classpath = src; } else { classpath.append(src); } } /** * Path to use for classpath. * @return a path to be configured. */ public Path createClasspath() { if (classpath == null) { classpath = new Path(getProject()); } return classpath.createPath(); } /** * Adds a reference to a classpath defined elsewhere. * @param r a reference to a classpath. * @todo this needs to be documented in the HTML docs. */ public void setClasspathRef(Reference r) { createClasspath().setRefid(r); } /** * The classpath to use. * @return the classpath. * @since Ant 1.6.3 */ public Path getClasspath() { return classpath; } /** * location of bootstrap class files. * @param src the bootstrap classpath. */ public void setBootclasspath(Path src) { if (bootclasspath == null) { bootclasspath = src; } else { bootclasspath.append(src); } } /** * Adds path to bootstrap class files. * @return a path to be configured. */ public Path createBootclasspath() { if (bootclasspath == null) { bootclasspath = new Path(getProject()); } return bootclasspath.createPath(); }
void setClasspath(Path cp) { if (classpath == null) { classpath = cp; } else { classpath.append(cp); } } /** * Adds a path to the classpath. * @return a path to be configured. */ public Path createClasspath() { if (classpath == null) { classpath = new Path(getProject()); } return classpath.createPath(); } /** * Adds a reference to a classpath defined elsewhere * @param r a reference to a classpath. */ public void setClasspathRef(Reference r) { createClasspath().setRefid(r); } /** * Get the classpath. * @return the classpath. */ public Path getClasspath() { return classpath; } /** * Set the classpath to be used to find this compiler adapter * @param cp the compiler classpath. */ public void setCompilerclasspath(Path cp) { if (compilerClasspath == null) { compilerClasspath = cp; } else { compilerClasspath.append(cp); } } /** * get the classpath used to find the compiler adapter * @return the compiler classpath. */ public Path getCompilerclasspath() { return compilerClasspath; } /** * Support nested compiler classpath, used to locate compiler adapter * @return a path to be configured. */ public Path createCompilerclasspath() { if (compilerClasspath == null) { compilerClasspath = new Path(getProject()); } return compilerClasspath.createPath(); }
Clone fragments detected by clone detection tool
File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/Javah.java File path: /apache-ant-1.7.0/src/org/apache/tools/ant/taskdefs/optional/jsp/JspC.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void setClasspath(Path src) {
1
void setClasspath(Path cp) {
2
        if (classpath == null) {
2
        if (classpath == null) {
3
            classpath = src;
3
            classpath = cp;
4
        } else {
4
        } else {
5
            classpath.append(src);
5
            classpath.append(cp);
6
        }
6
        }
7
    }
7
    }
8
    /**
8
    /**
9
     * Path to use for classpath.
9
     * Adds a path to the classpath.
10
     * @return a path to be configured.
10
     * @return a path to be configured.
11
     */
11
     */
12
    public Path createClasspath() {
12
    public Path createClasspath() {
13
        if (classpath == null) {
13
        if (classpath == null) {
14
            classpath = new Path(getProject());
14
            classpath = new Path(getProject());
15
        }
15
        }
16
        return classpath.createPath();
16
        return classpath.createPath();
17
    }
17
    }
18
    /**
18
    /**
19
     * Adds a reference to a classpath defined elsewhere.
19
     * Adds a reference to a classpath defined elsewhere
20
     * @param r a reference to a classpath.
20
     * @param r a reference to a classpath.
21
     * @todo this needs to be documented in the HTML docs.
22
     */
21
     */
23
    public void setClasspathRef(Reference r) {
22
    public void setClasspathRef(Reference r) {
24
        createClasspath().setRefid(r);
23
        createClasspath().setRefid(r);
25
    }
24
    }
26
    /**
25
    /**
27
     * The classpath to use.
26
     * Get the classpath.
28
     * @return the classpath.
27
     * @return the classpath.
29
     * @since Ant 1.6.3
30
     */
28
     */
31
    public Path getClasspath() {
29
    public Path getClasspath() {
32
        return classpath;
30
        return classpath;
33
    }
31
    }
34
    /**
32
    /**
35
     * location of bootstrap class files.
33
     * Set the classpath to be used to find this compiler adapter
36
     * @param src the bootstrap classpath.
34
     * @param cp the compiler classpath.
37
     */
35
     */
38
    public void setBootclasspath(Path src) {
36
    public void setCompilerclasspath(Path cp) {
39
        if (bootclasspath == null) {
37
        if (compilerClasspath == null) {
40
            bootclasspath = src;
38
            compilerClasspath = cp;
41
        } else {
39
        } else {
42
            bootclasspath.append(src);
40
            compilerClasspath.append(cp);
43
        }
41
        }
44
    }
42
    }
45
    /**
43
    /**
46
     * Adds path to bootstrap class files.
44
     * get the classpath used to find the compiler adapter
45
     * @return the compiler classpath.
46
     */
47
    public Path getCompilerclasspath() {
48
        return compilerClasspath;
49
    }
50
    /**
51
     * Support nested compiler classpath, used to locate compiler adapter
47
     * @return a path to be configured.
52
     * @return a path to be configured.
48
     */
53
     */
49
    public Path createBootclasspath() {
54
    public Path createCompilerclasspath() {
50
        if (bootclasspath == null) {
55
        if (compilerClasspath == null) {
51
            bootclasspath = new Path(getProject());
56
            compilerClasspath = new Path(getProject());
52
        }
57
        }
53
        return bootclasspath.createPath();
58
        return compilerClasspath.createPath();
54
    }
59
    }
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