void setFilename(String value) { fileList = null; // Force rebuild setFilenameProperty(value); } private void setFilenameProperty(String value) { if (value == null) { throw new IllegalArgumentException("Value must not be null"); } setProperty(FILE_NAME, value); } /** * The actual name of the file to POST * @deprecated Use getHTTPFiles() array instead */ public String getFilename() { checkCount("getFilename"); return getFilenameProperty(); } private String getFilenameProperty() { return getPropertyAsString(FILE_NAME); } /** * Set the files mime type * @deprecated use setHTTPFiles() instead * @param value */ public void setMimetype(String value) { fileList = null; // Force rebuild setMimetypeProperty(value); } private void setMimetypeProperty(String value) { if (value == null) { throw new IllegalArgumentException("Value must not be null"); } setProperty(MIMETYPE, value); } /** * @deprecated Use getHTTPFiles() array instead */ public String getMimetype() { checkCount("getMimetype"); return getMimetypeProperty(); } private String getMimetypeProperty() { return getPropertyAsString(MIMETYPE); }
void setFileField(String value) { fileList = null; // Force rebuild setFileFieldProperty(value); } private void setFileFieldProperty(String value) { if (value == null) { throw new IllegalArgumentException("Value must not be null"); } setProperty(FILE_FIELD, value); } /** * The name parameter to be applied to the file * @deprecated Use getHTTPFiles() array instead */ public String getFileField() { checkCount("getFileField"); return getFileFieldProperty(); } private String getFileFieldProperty() { return getPropertyAsString(FILE_FIELD); } /** * The actual name of the file to POST * @deprecated use setHTTPFiles() instead */ public void setFilename(String value) { fileList = null; // Force rebuild setFilenameProperty(value); } private void setFilenameProperty(String value) { if (value == null) { throw new IllegalArgumentException("Value must not be null"); } setProperty(FILE_NAME, value); } /** * The actual name of the file to POST * @deprecated Use getHTTPFiles() array instead */ public String getFilename() { checkCount("getFilename"); return getFilenameProperty(); } private String getFilenameProperty() { return getPropertyAsString(FILE_NAME); }
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/sampler/HTTPSamplerBase.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
void setFilename(String value) {
1
void setFileField(String value) {
2
	    fileList = null; // Force rebuild
2
        fileList = null; // Force rebuild
3
		setFilenameProperty(value);
3
        setFileFieldProperty(value);
4
	}
4
	}
5
    private void setFilenameProperty(String value) {
5
    private void setFileFieldProperty(String value) {
6
        if (value == null) {
6
        if (value == null) {
7
            throw new IllegalArgumentException("Value must not be null");
7
            throw new IllegalArgumentException("Value must not be null");
8
        }
8
        }
9
        setProperty(FILE_NAME, value);
9
        setProperty(FILE_FIELD, value);
10
    }
10
    }
11
    /**
11
    /**
12
     * The actual name of the file to POST
12
     * The name parameter to be applied to the file
13
     * @deprecated Use getHTTPFiles() array instead
13
     * @deprecated Use getHTTPFiles() array instead
14
     */
14
     */
15
	public String getFilename() {
15
	public String getFileField() {
16
	    checkCount("getFilename");
16
        checkCount("getFileField");
17
		return getFilenameProperty();
17
		return getFileFieldProperty();
18
	}
18
	}
19
    private String getFilenameProperty() {
19
    private String getFileFieldProperty() {
20
        return getPropertyAsString(FILE_NAME);
20
        return getPropertyAsString(FILE_FIELD);
21
    }
21
    }
22
    /**
22
    /**
23
     * Set the files mime type
23
     * The actual name of the file to POST
24
     * @deprecated use setHTTPFiles() instead
24
     * @deprecated use setHTTPFiles() instead
25
     * @param value
25
     *
26
     */
27
    
26
/
28
public void setMimetype(String value) {
27
	public void setFilename(String value) {
29
        fileList = null; // Force rebuild
28
	    fileList = null; // Force rebuild
30
        setMimetypeProperty(value);
29
		setFilenameProperty(value);
31
    }
30
	}
32
    private void setMimetypeProperty(String value) {
31
    private void setFilenameProperty(String value) {
33
        if (value == null) {
32
        if (value == null) {
34
            throw new IllegalArgumentException("Value must not be null");
33
            throw new IllegalArgumentException("Value must not be null");
35
        }
34
        }
36
        setProperty(MIMETYPE, value);
35
        setProperty(FILE_NAME, value);
37
    }
36
    }
38
    /**
37
    /**
38
     * The actual name of the file to POST
39
     * @deprecated Use getHTTPFiles() array instead
39
     * @deprecated Use getHTTPFiles() array instead
40
     */
40
     */
41
    public String getMimetype() {
41
	public String getFilename() {
42
        checkCount("getMimetype");
42
	    checkCount("get
43
        
43
Filename");
44
return getMimetypeProperty();
44
		return getFilenameProperty();
45
    }
45
	}
46
    private String getMimetypeProperty() {
46
    private String getFilenameProperty() {
47
        return getPropertyAsString(MIMETYPE);
47
        return getPropertyAsString(FILE_NAME);
48
    }
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