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/jorphan/collections/Data.java | |||
Method name: HTTPSampleResult followRedirects(HTTPSampleResult, int)
|
Method name: void append(Data)
|
|||
Number of AST nodes: 3 | Number of AST nodes: 3 | |||
1 | SampleResult[] subs = lastRes.getSubResults();↵ | 1 | while (d.next()) {↵ | |
2 | for (int i = 0; i < subs.length; i++) {↵ | 2 | for (int count = 0; count < headers.length; count++) {↵ | |
3 | totalRes.addSubResult(subs[i]);↵ | 3 | addColumnValue(headers[count], d.getColumnValue(headers[count]));↵ | |
4 | } | 4 | }↵ | |
5 |
| |||
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 | 7 |
Number of mapped statements | 2 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 11.3 |
Clone type | Type 3 |
ID | Statement | ID | Statement | |||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
10 | SampleResult[] subs = lastRes.getSubResults(); |
| | |||||||||||||||||||||||||
11 | for (int i = 0; i < subs.length; i++) |
| 13 | for (int count = 0; count < headers.length; count++) | ||||||||||||||||||||||||
12 | totalRes.addSubResult(subs[i]); |
| 14 | addColumnValue(headers[count], d.getColumnValue(headers[count])); |
Row | Violation |
---|---|
1 | Unmatched statement SampleResult[] subs=lastRes.getSubResults(); cannot be moved before or after the extracted code, because it has dependencies to/from statements that will be extracted |
2 | Type org.apache.jmeter.samplers.SampleResult[] of variable subs does not match with type java.lang.String[] of variable headers |
3 | Expression totalRes.addSubResult(subs[i]) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression addColumnValue(headers[count],d.getColumnValue(headers[count])) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
5 | Expression totalRes.addSubResult(subs[i]) is a void method call, and thus it cannot be parameterized |
6 | Expression addColumnValue(headers[count],d.getColumnValue(headers[count])) is a void method call, and thus it cannot be parameterized |
7 | Expression totalRes.addSubResult(subs[i]) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
8 | Expression addColumnValue(headers[count],d.getColumnValue(headers[count])) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
9 | Expression totalRes.addSubResult(subs[i]) is a void method call, and thus it cannot be parameterized |
10 | Expression addColumnValue(headers[count],d.getColumnValue(headers[count])) is a void method call, and thus it cannot be parameterized |