File path: /jfreechart-1.0.10/src/org/jfree/chart/renderer/category/StatisticalLineAndShapeRenderer.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/title/ImageTitle.java | |||
Method name: boolean equals(Object)
|
Method name: boolean equals(Object)
|
|||
Number of AST nodes: 8 | Number of AST nodes: 8 | |||
1 | if (obj == this) {↵ | 1 | if (obj == this) {↵ | |
2 | return true;↵ | 2 | return true;↵ | |
3 | }↵ | 3 | }↵ | |
4 | if (!(obj instanceof StatisticalLineAndShapeRenderer)) {↵ | 4 | if (!(obj instanceof ImageTitle)) {↵ | |
5 | return false;↵ | 5 | return false;↵ | |
6 | }↵ | 6 | }↵ | |
7 | StatisticalLineAndShapeRenderer that↵ | 7 | ↵ | |
8 | = (StatisticalLineAndShapeRenderer) obj;↵ | 8 | ImageTitle that = (ImageTitle) obj;↵ | |
9 | if (!PaintUtilities.equal(this.errorIndicatorPaint,↵ | 9 | if (!ObjectUtilities.equal(this.↵ | |
10 | that.errorIndicatorPaint)) {↵ | 10 | image, that.image)) {↵ | |
11 | return false;↵ | 11 | return false;↵ | |
12 | }↵ | 12 | }↵ | |
13 | return super.equals(obj); | 13 |
| |
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.9 |
Clones location | Clones are in different classes |
Number of node comparisons | 25 |
Number of mapped statements | 7 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 1.9 |
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 StatisticalLineAndShapeRenderer)) |
| 3 | if (!(obj instanceof ImageTitle)) | |||||||||||||||||||||||||||||||
4 | return false; | 4 | return false; | ||||||||||||||||||||||||||||||||
| 5 | ImageTitle that = (ImageTitle)obj; | |||||||||||||||||||||||||||||||||
5 | StatisticalLineAndShapeRenderer that = (StatisticalLineAndShapeRenderer)obj; | | |||||||||||||||||||||||||||||||||
6 | if (!PaintUtilities.equal(this.errorIndicatorPaint, that.errorIndicatorPaint)) |
| 6 | if (!ObjectUtilities.equal(this.image, that.image)) | |||||||||||||||||||||||||||||||
7 | return false; | 7 | return false; | ||||||||||||||||||||||||||||||||
8 | return super.equals(obj); |
| 8 | return super.equals(obj); |
Row | Violation |
---|---|
1 | Type org.jfree.chart.renderer.category.StatisticalLineAndShapeRenderer does not match with type org.jfree.chart.title.ImageTitle |
2 | Type java.awt.Paint of variable this.errorIndicatorPaint does not match with type java.awt.Image of variable this.image |
3 | Type java.awt.Paint of variable that.errorIndicatorPaint does not match with type java.awt.Image of variable that.image |
4 | Expression that.errorIndicatorPaint cannot be parameterized, because it has dependencies to/from statements that will be extracted |
5 | Expression that.image cannot be parameterized, because it has dependencies to/from statements that will be extracted |
6 | Type java.awt.Paint of variable that.errorIndicatorPaint does not match with type java.awt.Image of variable that.image |
7 | Type org.jfree.util.PaintUtilities does not match with type org.jfree.util.ObjectUtilities |
8 | Super method call return super.equals(obj); cannot be extracted from method |
9 | Super method call return super.equals(obj); cannot be extracted from method |
10 | The refactoring of the clones is infeasible, because classes org.jfree.chart.renderer.category.StatisticalLineAndShapeRenderer and org.jfree.chart.title.ImageTitle do not have a common superclass |