File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/http/proxy/HttpRequestHdr.java | File path: /jakarta-jmeter-2.3.2/src/org/apache/jorphan/collections/HashTree.java | |||
Method name: String getContentType()
|
Method name: Collection list(Object)
|
|||
Number of AST nodes: 4 | Number of AST nodes: 4 | |||
1 | Header contentTypeHeader = (Header) headers.get(CONTENT_TYPE);↵ | 1 | H↵ | |
2 | if (contentTypeHeader != null) {↵ | |||
3 | return contentTypeHeader.getValue();↵ | |||
4 | }↵ | |||
5 | return null↵ | 2 | ashTree temp = (HashTree) data.get(key);↵ | |
3 | if (temp != null) {↵ | |||
4 | return temp.list();↵ | |||
5 | }↵ | |||
6 | ; | 6 | return new LinkedList(); | |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1 |
Clones location | Clones are in different classes |
Number of node comparisons | 8 |
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 2 |
Number of unmapped statements in the second code fragment | 2 |
Time elapsed for statement mapping (ms) | 0.5 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 | HashTree temp = (HashTree)data.get(key); | ||||||||||||||||
1 | Header contentTypeHeader = (Header)headers.get(CONTENT_TYPE); | | ||||||||||||||||
2 | if (contentTypeHeader != null) |
| 2 | if (temp != null) | ||||||||||||||
|
| 3 | return temp.list(); | |||||||||||||||
3 | return contentTypeHeader.getValue(); |
| | |||||||||||||||
4 | return null; |
| 4 | return new LinkedList(); |
Row | Violation |
---|---|
1 | Type org.apache.jmeter.protocol.http.control.Header of variable contentTypeHeader does not match with type org.apache.jorphan.collections.HashTree of variable temp |
2 | Unmatched return temp.list(); |
3 | Unmatched return contentTypeHeader.getValue(); |