File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/samplers/SampleResult.java | File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/MainFrame.java | |||
Method name: String getDataEncodingWithDefault()
|
Method name: String getToolTipText(MouseEvent)
|
|||
Number of AST nodes: 3 | Number of AST nodes: 4 | |||
1 | if (dataEncoding != null && dataEncoding↵ | 1 | if (testElement instanceof TestElement) {↵ | |
2 | String comment = ((TestElement) testElement).getComment();↵ | |||
2 | .length() > 0) {↵ | 3 | if (comment != null && comment.length() > 0) {↵ | |
3 | return dataEncoding;↵ | 4 | return ↵ | |
4 | }↵ | |||
5 | return DEFAULT_ENCODING; | 5 | comment;↵ | |
6 | }↵ | |||
7 |
| |||
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.2 |
Clones location | Clones are in different classes |
Number of node comparisons | 5 |
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 0.5 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 7 | String comment = ((TestElement)testElement).getComment(); | |||||||||||||||
1 | if (dataEncoding != null && dataEncoding.length() > 0) |
| 8 | if (comment != null && comment.length() > 0) | |||||||||||||
2 | return dataEncoding; |
| 9 | return comment; | |||||||||||||
3 | return DEFAULT_ENCODING; |
| |
Row | Violation |
---|---|
1 | Unmatched return DEFAULT_ENCODING; |