File path: /jfreechart-1.0.10/src/org/jfree/chart/renderer/category/BoxAndWhiskerRenderer.java | File path: /jfreechart-1.0.10/src/org/jfree/data/time/Millisecond.java | |||
Method name: boolean equals(Object)
|
Method name: boolean equals(Object)
|
|||
Number of AST nodes: 16 | Number of AST nodes: 16 | |||
1 | if (obj == this) {↵ | 1 | if (obj == this) {↵ | |
2 | return true;↵ | 2 | return true;↵ | |
3 | }↵ | 3 | }↵ | |
4 | if (!(obj instanceof BoxAndWhiskerRenderer)) {↵ | 4 | if (!(obj instanceof Millisecond)) {↵ | |
5 | return false;↵ | 5 | return false;↵ | |
6 | }↵ | 6 | }↵ | |
7 | if (!super.equals(obj)) {↵ | 7 | ↵ | |
8 | return false;↵ | |||
9 | }↵ | |||
10 | BoxAndWhiskerRenderer that = (BoxAndWhiskerRenderer) obj;↵ | |||
11 | if (!PaintUtilities.equal(this.artifactPaint, that.artifactPaint)↵ | 8 | Millisecond that = (Millisecond) obj;↵ | |
9 | if (this.millisecond != that.millisecond) {↵ | |||
10 | return false;↵ | |||
11 | }↵ | |||
12 | ) {↵ | 12 | if (this.second != that.second) {↵ | |
13 | return false;↵ | 13 | return false;↵ | |
14 | }↵ | 14 | }↵ | |
15 | if (this.fillBox != that.fillBox) {↵ | 15 | if (this.minute != that.minute) {↵ | |
16 | return false;↵ | 16 | return false;↵ | |
17 | }↵ | 17 | }↵ | |
18 | if (this.itemMargin != that.itemMargin) {↵ | 18 | if (this.hour != that.hour) {↵ | |
19 | return false;↵ | 19 | return false;↵ | |
20 | }↵ | 20 | }↵ | |
21 | if (this.maximumBarWidth != that.maximumBarWidth) {↵ | 21 | if (!this.day.equals(that.day)) {↵ | |
22 | return false;↵ | 22 | return false;↵ | |
23 | }↵ | 23 | }↵ | |
24 | return true; | 24 |
| |
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) | 4.1 |
Clones location | Clones are in different classes |
Number of node comparisons | 89 |
Number of mapped statements | 12 |
Number of unmapped statements in the first code fragment | 3 |
Number of unmapped statements in the second code fragment | 3 |
Time elapsed for statement mapping (ms) | 9.8 |
Clone type | Type 3 |
ID | Statement | ID | Statement | ||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | if (obj == this) | 1 | if (obj == this) | ||||||||||||||||||||||||||||
2 | return true; | 2 | return true; | ||||||||||||||||||||||||||||
3 | if (!(obj instanceof BoxAndWhiskerRenderer)) |
| 3 | if (!(obj instanceof Millisecond)) | |||||||||||||||||||||||||||
4 | return false; | 4 | return false; | ||||||||||||||||||||||||||||
| 5 | Millisecond that = (Millisecond)obj; | |||||||||||||||||||||||||||||
| 6 | if (this.millisecond != that.millisecond) | |||||||||||||||||||||||||||||
|
| 7 | return false; | ||||||||||||||||||||||||||||
5 | if (!super.equals(obj)) |
| 14 | if (!this.day.equals(that.day)) | |||||||||||||||||||||||||||
6 | return false; | 15 | return false; | ||||||||||||||||||||||||||||
7 | BoxAndWhiskerRenderer that = (BoxAndWhiskerRenderer)obj; | | |||||||||||||||||||||||||||||
8 | if (!PaintUtilities.equal(this.artifactPaint, that.artifactPaint)) | | |||||||||||||||||||||||||||||
9 | return false; |
| | ||||||||||||||||||||||||||||
10 | if (this.fillBox != that.fillBox) |
| 10 | if (this.minute != that.minute) | |||||||||||||||||||||||||||
11 | return false; | 11 | return false; | ||||||||||||||||||||||||||||
12 | if (this.itemMargin != that.itemMargin) |
| 12 | if (this.hour != that.hour) | |||||||||||||||||||||||||||
13 | return false; | 13 | return false; | ||||||||||||||||||||||||||||
14 | if (this.maximumBarWidth != that.maximumBarWidth) |
| 8 | if (this.second != that.second) | |||||||||||||||||||||||||||
15 | return false; | 9 | return false; |
Row | Violation |
---|---|
1 | Type org.jfree.chart.renderer.category.BoxAndWhiskerRenderer does not match with type org.jfree.data.time.Millisecond |
2 | Unmatched return false; |
3 | Expression this.day.equals(that.day) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Super method call if(!super.equals(obj)) cannot be extracted from method |
5 | Unmatched return false; |
6 | Type boolean of variable this.fillBox does not match with type byte of variable this.minute |
7 | Type boolean of variable that.fillBox does not match with type byte of variable that.minute |
8 | Expression that.fillBox cannot be parameterized, because it has dependencies to/from statements that will be extracted |
9 | Expression that.minute cannot be parameterized, because it has dependencies to/from statements that will be extracted |
10 | Type boolean of variable that.fillBox does not match with type byte of variable that.minute |
11 | Type double of variable this.itemMargin does not match with type byte of variable this.hour |
12 | Type double of variable that.itemMargin does not match with type byte of variable that.hour |
13 | Expression that.itemMargin cannot be parameterized, because it has dependencies to/from statements that will be extracted |
14 | Expression that.hour cannot be parameterized, because it has dependencies to/from statements that will be extracted |
15 | Type double of variable that.itemMargin does not match with type byte of variable that.hour |
16 | Type double of variable this.maximumBarWidth does not match with type byte of variable this.second |
17 | Type double of variable that.maximumBarWidth does not match with type byte of variable that.second |
18 | Expression that.maximumBarWidth cannot be parameterized, because it has dependencies to/from statements that will be extracted |
19 | Expression that.second cannot be parameterized, because it has dependencies to/from statements that will be extracted |
20 | Type double of variable that.maximumBarWidth does not match with type byte of variable that.second |
21 | Not all possible execution flows end in a return statement |
22 | The refactoring of the clones is infeasible, because classes org.jfree.chart.renderer.category.BoxAndWhiskerRenderer and org.jfree.data.time.Millisecond do not have a common superclass |