File path: /jfreechart-1.0.10/src/org/jfree/data/category/SlidingCategoryDataset.java | File path: /jfreechart-1.0.10/src/org/jfree/data/time/TimeSeriesCollection.java | |||
Method name: boolean equals(Object)
|
Method name: boolean equals(Object)
|
|||
Number of AST nodes: 12 | Number of AST nodes: 12 | |||
1 | if (obj == this) {↵ | 1 | if (obj == this) {↵ | |
2 | return true;↵ | 2 | return true;↵ | |
3 | }↵ | |||
4 | ↵ | 3 | }↵ | |
5 | if (!(obj instanceof SlidingCategoryDataset)) {↵ | 4 | if (!(obj instanceof ↵ | |
6 | return false;↵ | |||
7 | }↵ | |||
8 | SlidingCategoryDataset that = (SlidingCategoryDataset) obj;↵ | |||
9 | if (this.firstCategoryIndex != that.firstCategoryIndex) {↵ | |||
10 | return false;↵ | |||
11 | }↵ | |||
12 | ↵ | 5 | TimeSeriesCollection)) {↵ | |
6 | return false;↵ | |||
7 | }↵ | |||
8 | TimeSeriesCollection that = (TimeSeriesCollection) obj;↵ | |||
9 | if (this.xPosition != that.xPosition) {↵ | |||
10 | return false;↵ | |||
11 | }↵ | |||
13 | if (this.maximumCategoryCount != that.maximumCategoryCount) {↵ | 12 | if (this.domainIsPointsInTime != that.↵ | |
14 | return false;↵ | |||
15 | }↵ | |||
16 | if (!this.underlying.equals(that.underlying)) {↵ | |||
17 | return false;↵ | |||
18 | }↵ | |||
19 | ↵ | 13 | domainIsPointsInTime) {↵ | |
14 | return false;↵ | |||
15 | }↵ | |||
16 | if (!ObjectUtilities.equal(this.data, that.data)) {↵ | |||
17 | return false;↵ | |||
18 | }↵ | |||
20 | return true; | 19 | return true; | |
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) | 2.9 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 50 |
Number of mapped statements | 12 |
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) | 4.6 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | if (obj == this) | 1 | if (obj == this) | |||||||||||||||||||||||||||
2 | return true; | 2 | return true; | |||||||||||||||||||||||||||
3 | if (!(obj instanceof SlidingCategoryDataset)) |
| 3 | if (!(obj instanceof TimeSeriesCollection)) | ||||||||||||||||||||||||||
4 | return false; | 4 | return false; | |||||||||||||||||||||||||||
5 | SlidingCategoryDataset that = (SlidingCategoryDataset)obj; |
| 5 | TimeSeriesCollection that = (TimeSeriesCollection)obj; | ||||||||||||||||||||||||||
6 | if (this.firstCategoryIndex != that.firstCategoryIndex) |
| 6 | if (this.xPosition != that.xPosition) | ||||||||||||||||||||||||||
7 | return false; | 7 | return false; | |||||||||||||||||||||||||||
8 | if (this.maximumCategoryCount != that.maximumCategoryCount) |
| 8 | if (this.domainIsPointsInTime != that.domainIsPointsInTime) | ||||||||||||||||||||||||||
9 | return false; | 9 | return false; | |||||||||||||||||||||||||||
10 | if (!this.underlying.equals(that.underlying)) |
| 10 | if (!ObjectUtilities.equal(this.data, that.data)) | ||||||||||||||||||||||||||
11 | return false; | 11 | return false; | |||||||||||||||||||||||||||
12 | return true; | 12 | return true; |
Row | Violation |
---|---|
1 | Type int of variable this.firstCategoryIndex does not match with type org.jfree.data.time.TimePeriodAnchor of variable this.xPosition |
2 | Expression that.firstCategoryIndex cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression that.xPosition cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Type int of variable that.firstCategoryIndex does not match with type org.jfree.data.time.TimePeriodAnchor of variable that.xPosition |
5 | Type int of variable this.maximumCategoryCount does not match with type boolean of variable this.domainIsPointsInTime |
6 | Expression that.maximumCategoryCount cannot be parameterized, because it has dependencies to/from statements that will be extracted |
7 | Expression that.domainIsPointsInTime cannot be parameterized, because it has dependencies to/from statements that will be extracted |
8 | Type int of variable that.maximumCategoryCount does not match with type boolean of variable that.domainIsPointsInTime |
9 | Expression this.underlying.equals(that.underlying) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
10 | Expression ObjectUtilities.equal(this.data,that.data) cannot be parameterized, because it has dependencies to/from statements that will be extracted |