File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/Marker.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/plot/dial/DialValueIndicator.java | |||
Method name: boolean equals(Object)
|
Method name: boolean equals(Object)
|
|||
Number of AST nodes: 30 | Number of AST nodes: 32 | |||
1 | if (obj == this) {↵ | 1 | if (obj == this) {↵ | |
2 | return true;↵ | 2 | return true;↵ | |
3 | }↵ | 3 | }↵ | |
4 | if (!(obj instanceof Marker)) {↵ | 4 | if (!(obj instanceof DialValueIndicator)) {↵ | |
5 | return false;↵ | 5 | return false;↵ | |
6 | }↵ | 6 | }↵ | |
7 | Marker that = (Marker) obj;↵ | 7 | ↵ | |
8 | if (!PaintUtilities.equal(this.paint, that.paint)↵ | 8 | DialValueIndicator that = (DialValueIndicator) obj;↵ | |
9 | ) {↵ | 9 | if (this.datasetIndex != that.datasetIndex) {↵ | |
10 | return false; ↵ | 10 | return false;↵ | |
11 | }↵ | 11 | }↵ | |
12 | if (!ObjectUtilities.equal(this.stroke, that.stroke)) {↵ | 12 | if (this.angle != that.angle) {↵ | |
13 | return false;↵ | 13 | return false;↵ | |
14 | }↵ | 14 | }↵ | |
15 | if (!PaintUtilities.equal(this.outlinePaint, that.outlinePaint)) {↵ | 15 | if (this.radius != that.radius) {↵ | |
16 | return false; ↵ | 16 | return false;↵ | |
17 | }↵ | 17 | }↵ | |
18 | if (!ObjectUtilities.equal(this.outlineStroke, that.outlineStroke)) {↵ | 18 | if (!this.frameAnchor.equals(that.frameAnchor)) {↵ | |
19 | return false;↵ | 19 | return false;↵ | |
20 | }↵ | 20 | }↵ | |
21 | if (this.alpha != that.alpha) {↵ | 21 | if (!this.templateValue.equals(that.templateValue)) {↵ | |
22 | return false;↵ | 22 | return false;↵ | |
23 | }↵ | 23 | }↵ | |
24 | if (!ObjectUtilities.equal(this.label, that.label)) {↵ | 24 | if (!this.font.equals(that.font)) {↵ | |
25 | return false;↵ | 25 | return false;↵ | |
26 | }↵ | 26 | }↵ | |
27 | if (!ObjectUtilities.equal(this.labelFont, that.labelFont)) {↵ | 27 | if (!PaintUtilities.equal(this.paint, that.paint)) {↵ | |
28 | return false;↵ | 28 | return false;↵ | |
29 | }↵ | 29 | }↵ | |
30 | if (!PaintUtilities.equal(this.labelPaint, that.labelPaint)) {↵ | 30 | if (!PaintUtilities.equal(this.backgroundPaint, that.backgroundPaint)) {↵ | |
31 | return false;↵ | 31 | return false;↵ | |
32 | }↵ | 32 | }↵ | |
33 | if (this.labelAnchor != that.labelAnchor) {↵ | 33 | if (!this.outlineStroke.equals(that.outlineStroke)) {↵ | |
34 | return false;↵ | 34 | return false;↵ | |
35 | }↵ | 35 | }↵ | |
36 | if (this.labelTextAnchor != that.labelTextAnchor) {↵ | 36 | if (!PaintUtilities.equal(this.outlinePaint, that.outlinePaint)) {↵ | |
37 | return false; ↵ | 37 | return false;↵ | |
38 | }↵ | 38 | }↵ | |
39 | if (!ObjectUtilities.equal(this.labelOffset, that.labelOffset↵ | 39 | if (!this.insets.equals(that.insets)) {↵ | |
40 | return false;↵ | |||
41 | }↵ | |||
40 | )) {↵ | 42 | if (!this.valueAnchor.equals(that.valueAnchor)) {↵ | |
41 | return false;↵ | 43 | return false;↵ | |
42 | }↵ | 44 | }↵ | |
43 | if (!this.labelOffsetType.equals(that.labelOffsetType)) {↵ | 45 | if (!this.textAnchor.equals(that.textAnchor)) {↵ | |
44 | return false;↵ | 46 | return false;↵ | |
45 | }↵ | 47 | }↵ | |
46 | return true↵ | 48 | ↵ | |
47 | ; | 49 | return super.equals(obj); | |
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) | 18.3 |
Clones location | Clones are in different classes |
Number of node comparisons | 400 |
Number of mapped statements | 29 |
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) | 18.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 Marker)) |
| 3 | if (!(obj instanceof DialValueIndicator)) | |||||||||||||||||||||||||||||||
4 | return false; | 4 | return false; | ||||||||||||||||||||||||||||||||
| 5 | DialValueIndicator that = (DialValueIndicator)obj; | |||||||||||||||||||||||||||||||||
5 | Marker that = (Marker)obj; | | |||||||||||||||||||||||||||||||||
6 | if (!PaintUtilities.equal(this.paint, that.paint)) |
| 18 | if (!PaintUtilities.equal(this.paint, that.paint)) | |||||||||||||||||||||||||||||||
7 | return false; | 19 | return false; | ||||||||||||||||||||||||||||||||
8 | if (!ObjectUtilities.equal(this.stroke, that.stroke)) |
| 20 | if (!PaintUtilities.equal(this.backgroundPaint, that.backgroundPaint)) | |||||||||||||||||||||||||||||||
9 | return false; | 21 | return false; | ||||||||||||||||||||||||||||||||
10 | if (!PaintUtilities.equal(this.outlinePaint, that.outlinePaint)) |
| 24 | if (!PaintUtilities.equal(this.outlinePaint, that.outlinePaint)) | |||||||||||||||||||||||||||||||
11 | return false; | 25 | return false; | ||||||||||||||||||||||||||||||||
12 | if (!ObjectUtilities.equal(this.outlineStroke, that.outlineStroke)) |
| 12 | if (!this.frameAnchor.equals(that.frameAnchor)) | |||||||||||||||||||||||||||||||
13 | return false; | 13 | return false; | ||||||||||||||||||||||||||||||||
14 | if (this.alpha != that.alpha) |
| 10 | if (this.radius != that.radius) | |||||||||||||||||||||||||||||||
15 | return false; | 11 | return false; | ||||||||||||||||||||||||||||||||
16 | if (!ObjectUtilities.equal(this.label, that.label)) |
| 16 | if (!this.font.equals(that.font)) | |||||||||||||||||||||||||||||||
17 | return false; | 17 | return false; | ||||||||||||||||||||||||||||||||
18 | if (!ObjectUtilities.equal(this.labelFont, that.labelFont)) |
| 14 | if (!this.templateValue.equals(that.templateValue)) | |||||||||||||||||||||||||||||||
19 | return false; | 15 | return false; | ||||||||||||||||||||||||||||||||
20 | if (!PaintUtilities.equal(this.labelPaint, that.labelPaint)) |
| 22 | if (!this.outlineStroke.equals(that.outlineStroke)) | |||||||||||||||||||||||||||||||
21 | return false; | 23 | return false; | ||||||||||||||||||||||||||||||||
22 | if (this.labelAnchor != that.labelAnchor) |
| 8 | if (this.angle != that.angle) | |||||||||||||||||||||||||||||||
23 | return false; | 9 | return false; | ||||||||||||||||||||||||||||||||
24 | if (this.labelTextAnchor != that.labelTextAnchor) |
| 6 | if (this.datasetIndex != that.datasetIndex) | |||||||||||||||||||||||||||||||
25 | return false; | 7 | return false; | ||||||||||||||||||||||||||||||||
26 | if (!ObjectUtilities.equal(this.labelOffset, that.labelOffset)) |
| 26 | if (!this.insets.equals(that.insets)) | |||||||||||||||||||||||||||||||
27 | return false; | 27 | return false; | ||||||||||||||||||||||||||||||||
28 | if (!this.labelOffsetType.equals(that.labelOffsetType)) |
| 28 | if (!this.valueAnchor.equals(that.valueAnchor)) | |||||||||||||||||||||||||||||||
29 | return false; | 29 | return false; | ||||||||||||||||||||||||||||||||
30 | return true; |
| 32 | return super.equals(obj); |
Row | Violation |
---|---|
1 | Type org.jfree.chart.plot.Marker does not match with type org.jfree.chart.plot.dial.DialValueIndicator |
2 | Type java.awt.Paint of variable that.paint does not match with type java.awt.Paint of variable that.paint |
3 | Type java.awt.Stroke of variable this.stroke does not match with type java.awt.Paint of variable this.backgroundPaint |
4 | Type java.awt.Stroke of variable that.stroke does not match with type java.awt.Paint of variable that.backgroundPaint |
5 | Expression that.stroke cannot be parameterized, because it has dependencies to/from statements that will be extracted |
6 | Expression that.backgroundPaint cannot be parameterized, because it has dependencies to/from statements that will be extracted |
7 | Type java.awt.Stroke of variable that.stroke does not match with type java.awt.Paint of variable that.backgroundPaint |
8 | Type org.jfree.util.ObjectUtilities does not match with type org.jfree.util.PaintUtilities |
9 | Type java.awt.Paint of variable that.outlinePaint does not match with type java.awt.Paint of variable that.outlinePaint |
10 | Expression ObjectUtilities.equal(this.outlineStroke,that.outlineStroke) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
11 | Expression this.frameAnchor.equals(that.frameAnchor) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
12 | Type float of variable this.alpha does not match with type double of variable this.radius |
13 | Type float of variable that.alpha does not match with type double of variable that.radius |
14 | Expression that.alpha cannot be parameterized, because it has dependencies to/from statements that will be extracted |
15 | Expression that.radius cannot be parameterized, because it has dependencies to/from statements that will be extracted |
16 | Type float of variable that.alpha does not match with type double of variable that.radius |
17 | Expression ObjectUtilities.equal(this.label,that.label) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
18 | Expression this.font.equals(that.font) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
19 | Expression ObjectUtilities.equal(this.labelFont,that.labelFont) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
20 | Expression this.templateValue.equals(that.templateValue) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
21 | Expression PaintUtilities.equal(this.labelPaint,that.labelPaint) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
22 | Expression this.outlineStroke.equals(that.outlineStroke) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
23 | Type org.jfree.ui.RectangleAnchor of variable this.labelAnchor does not match with type double of variable this.angle |
24 | Type org.jfree.ui.RectangleAnchor of variable that.labelAnchor does not match with type double of variable that.angle |
25 | Expression that.labelAnchor cannot be parameterized, because it has dependencies to/from statements that will be extracted |
26 | Expression that.angle cannot be parameterized, because it has dependencies to/from statements that will be extracted |
27 | Type org.jfree.ui.RectangleAnchor of variable that.labelAnchor does not match with type double of variable that.angle |
28 | Type org.jfree.ui.TextAnchor of variable this.labelTextAnchor does not match with type int of variable this.datasetIndex |
29 | Type org.jfree.ui.TextAnchor of variable that.labelTextAnchor does not match with type int of variable that.datasetIndex |
30 | Expression that.labelTextAnchor cannot be parameterized, because it has dependencies to/from statements that will be extracted |
31 | Expression that.datasetIndex cannot be parameterized, because it has dependencies to/from statements that will be extracted |
32 | Type org.jfree.ui.TextAnchor of variable that.labelTextAnchor does not match with type int of variable that.datasetIndex |
33 | Expression ObjectUtilities.equal(this.labelOffset,that.labelOffset) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
34 | Expression this.insets.equals(that.insets) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
35 | Type org.jfree.ui.LengthAdjustmentType of variable that.labelOffsetType does not match with type org.jfree.ui.RectangleAnchor of variable that.valueAnchor |
36 | Expression that.labelOffsetType cannot be parameterized, because it has dependencies to/from statements that will be extracted |
37 | Expression that.valueAnchor cannot be parameterized, because it has dependencies to/from statements that will be extracted |
38 | Type org.jfree.ui.LengthAdjustmentType of variable that.labelOffsetType does not match with type org.jfree.ui.RectangleAnchor of variable that.valueAnchor |
39 | Type org.jfree.ui.LengthAdjustmentType of variable this.labelOffsetType does not match with type org.jfree.ui.RectangleAnchor of variable this.valueAnchor |
40 | Super method call return super.equals(obj); cannot be extracted from method |
41 | Not all possible execution flows end in a return statement |
42 | The refactoring of the clones is infeasible, because classes org.jfree.chart.plot.Marker and org.jfree.chart.plot.dial.DialValueIndicator do not have a common superclass |