if (this.minStartIndex >= 0) {
long minStart = getDataItem(this.minStartIndex).getPeriod()
.getStart().getTime();
if (start < minStart) {
this.minStartIndex = index;
}
}
else {
this.minStartIndex = index;
}
if (this.maxStartIndex >= 0) {
long maxStart = getDataItem(this.maxStartIndex).getPeriod()
.getStart().getTime();
if (start > maxStart) {
this.maxStartIndex = index;
}
}
else {
this.maxStartIndex = index;
}
Clone fragments detected by clone detection tool
File path: /jfreechart-1.0.10/src/org/jfree/data/time/TimePeriodValues.java
|
|
File path: /jfreechart-1.0.10/src/org/jfree/data/time/TimePeriodValues.java
|
Method name: void updateBounds(TimePeriod, int)
|
|
Method name: void updateBounds(TimePeriod, int)
|
Number of AST nodes: 5
|
|
Number of AST nodes: 5
|
|
1 | if (this.minStartIndex >= 0) {↵ | | 1 | if (this.maxStartIndex >= 0) {↵
|
2 | long minStart = getDataItem(this.minStartIndex).getPeriod()↵ | | 2 | long maxStart = getDataItem(this.maxStartIndex).getPeriod()↵
|
3 | .getStart().getTime();↵ | | 3 | .getStart().getTime();↵
|
4 | if (start < minStart) {↵ | | 4 | if (start > maxStart) {↵
|
5 | this.minStartIndex = index; ↵ | | 5 | this.maxStartIndex = index; ↵
|
6 | }↵ | | 6 | }↵
|
7 | }↵ | | 7 | }↵
|
8 | else {↵ | | 8 | else {↵
|
9 | this.minStartIndex = index;↵ | | 9 | this.maxStartIndex = index;↵
|
10 | } | | 10 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.1 |
Clones location | Clones are in the same method |
Number of node comparisons | 1 |