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(); }
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
Path createClasspath() {
1
Path createClasspath() {
2
        if (classpath == null) {
2
        if (classpath == null) {
3
            classpath = new Path(getProject());
3
            classpath = new Path(getProject());
4
        }
4
        }
5
        return classpath.createPath();
5
        return classpath.createPath();
6
    }
6
    }
7
    /**
7
    /**
8
     * Adds a reference to a classpath defined elsewhere.
8
     * Adds a reference to a classpath defined elsewhere
9
     * @param r a reference to a classpath.
9
     * @param r a reference to a classpath.
10
     * @todo this needs to be documented in the HTML docs.
11
     */
10
     */
12
    public void setClasspathRef(Reference r) {
11
    public void setClasspathRef(Reference r) {
13
        createClasspath().setRefid(r);
12
        createClasspath().setRefid(r);
14
    }
13
    }
15
    /**
14
    /**
16
     * The classpath to use.
15
     * Get the classpath.
17
     * @return the classpath.
16
     * @return the classpath.
18
     * @since Ant 1.6.3
19
     */
17
     */
20
    public Path getClasspath() {
18
    public Path getClasspath() {
21
        return classpath;
19
        return classpath;
22
    }
20
    }
23
    /**
21
    /**
24
     * location of bootstrap class files.
22
     * Set the classpath to be used to find this compiler adapter
25
     * @param src the bootstrap classpath.
23
     * @param cp the compiler classpath.
26
     */
24
     */
27
    public void setBootclasspath(Path src) {
25
    public void setCompilerclasspath(Path cp) {
28
        if (bootclasspath == null) {
26
        if (compilerClasspath == null) {
29
            bootclasspath = src;
27
            compilerClasspath = cp;
30
        } else {
28
        } else {
31
            bootclasspath.append(src);
29
            compilerClasspath.append(cp);
32
        }
30
        }
33
    }
31
    }
34
    /**
32
    /**
35
     * Adds path to bootstrap class files.
33
     * get the classpath used to find the compiler adapter
34
     * @return the compiler classpath.
35
     */
36
    public Path getCompilerclasspath() {
37
        return compilerClasspath;
38
    }
39
    /**
40
     * Support nested compiler classpath, used to locate compiler adapter
36
     * @return a path to be configured.
41
     * @return a path to be configured.
37
     */
42
     */
38
    public Path createBootclasspath() {
43
    public Path createCompilerclasspath() {
39
        if (bootclasspath == null) {
44
        if (compilerClasspath == null) {
40
            bootclasspath = new Path(getProject());
45
            compilerClasspath = new Path(getProject());
41
        }
46
        }
42
        return bootclasspath.createPath();
47
        return compilerClasspath.createPath();
43
    }
48
    }
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