for (int j = 0; j < from.length; j++) {
cdata.append(from[j].toString());
if (j < from.length - 1) {
cdata.append("; "); // $NON-NLS-1$
}
}
for (int j = 0; j < recips.length; j++) {
cdata.append(recips[j].toString());
if (j < recips.length - 1) {
cdata.append("; "); // $NON-NLS-1$
}
}
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/mail/sampler/MailReaderSampler.java
|
|
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/protocol/mail/sampler/MailReaderSampler.java
|
Method name: SampleResult sample(Entry)
|
|
Method name: SampleResult sample(Entry)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 4
|
|
1 | for (int j = 0; j < from.length; j++) {↵ | | 1 | for (int j = 0; j < recips.length; j++) {↵
|
2 | cdata.append(from[j].toString());↵ | | 2 | cdata.append(recips[j].toString());↵
|
3 | if (j < from.length - 1) {↵ | | 3 | if (j < recips.length - 1) {↵
|
4 | cdata.append("; "); // $NON-NLS-1$↵ | | 4 | cdata.append("; "); // $NON-NLS-1$↵
|
5 | }↵ | | 5 | }↵
|
6 | } | | 6 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.3 |
Clones location | Clones are in the same method |
Number of node comparisons | 10 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 4 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 5.2 |
Clone type | Type 2 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
47 | for (int j = 0; j < from.length; j++) | | 40 | for (int j = 0; j < recips.length; j++) |
48 | cdata.append(from[j].toString()); | | 41 | cdata.append(recips[j].toString()); |
49 | | | 42 | if (j < recips.length - 1) |
50 | | | 43 | |
Precondition Violations (0)
Row |
Violation |