File path: /jfreechart-1.0.10/src/org/jfree/chart/ChartRenderingInfo.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/axis/CategoryTick.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 (this == obj) {↵ | |
2 | return true; ↵ | 2 | return true; ↵ | |
3 | }↵ | 3 | }↵ | |
4 | if (!(obj instanceof ChartRenderingInfo)) {↵ | 4 | if (obj instanceof C↵ | |
5 | return false;↵ | 5 | ategoryTick && super.equals(obj)) {↵ | |
6 | }↵ | 6 | ↵ | |
7 | ChartRenderingInfo that = (ChartRenderingInfo) obj;↵ | |||
7 | CategoryTick that = (CategoryTick) obj; ↵ | |||
8 | if (!ObjectUtilities.equal(this.chartArea, that.chartArea)) {↵ | 8 | if (!ObjectUtilities.equal(this.category, that.category)) {↵ | |
9 | return false; ↵ | 9 | return false; ↵ | |
10 | }↵ | 10 | }↵ | |
11 | if (!ObjectUtilities.equal(this.plotInfo, that.plotInfo)) {↵ | 11 | if (!ObjectUtilities.equal(this.label, that.label)) {↵ | |
12 | return false;↵ | 12 | return false;↵ | |
13 | ↵ | |||
13 | }↵ | 14 | }↵ | |
14 | if (!ObjectUtilities.equal(this.entities, that.entities)) {↵ | 15 | if (!ObjectUtilities.equal(this.labelAnchor, that.labelAnchor)) {↵ | |
15 | return false;↵ | 16 | return false; ↵ | |
16 | }↵ | 17 | ↵ | |
18 | }↵ | |||
17 | return true; | 19 | return true;↵ | |
20 | }↵ | |||
21 |
| |||
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.1 |
Clones location | Clones are in different classes |
Number of node comparisons | 34 |
Number of mapped statements | 6 |
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 | ||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 4 | CategoryTick that = (CategoryTick)obj; | |||||||||||||||||||||||||||||
3 | if (!(obj instanceof ChartRenderingInfo)) |
| 5 | if (!ObjectUtilities.equal(this.category, that.category)) | |||||||||||||||||||||||||||
4 | return false; | 6 | return false; | ||||||||||||||||||||||||||||
5 | ChartRenderingInfo that = (ChartRenderingInfo)obj; | | |||||||||||||||||||||||||||||
6 | if (!ObjectUtilities.equal(this.chartArea, that.chartArea)) |
| 7 | if (!ObjectUtilities.equal(this.label, that.label)) | |||||||||||||||||||||||||||
7 | return false; | 8 | return false; | ||||||||||||||||||||||||||||
8 | if (!ObjectUtilities.equal(this.plotInfo, that.plotInfo)) |
| 9 | if (!ObjectUtilities.equal(this.labelAnchor, that.labelAnchor)) | |||||||||||||||||||||||||||
9 | return false; | 10 | return false; |
Row | Violation |
---|---|
1 | Expression ObjectUtilities.equal(this.category,that.category) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Type java.awt.geom.Rectangle2D of variable this.chartArea does not match with type org.jfree.text.TextBlock of variable this.label |
3 | Type java.awt.geom.Rectangle2D of variable that.chartArea does not match with type org.jfree.text.TextBlock of variable that.label |
4 | Expression that.chartArea cannot be parameterized, because it has dependencies to/from statements that will be extracted |
5 | Expression that.label cannot be parameterized, because it has dependencies to/from statements that will be extracted |
6 | Type java.awt.geom.Rectangle2D of variable that.chartArea does not match with type org.jfree.text.TextBlock of variable that.label |
7 | Type org.jfree.chart.plot.PlotRenderingInfo of variable this.plotInfo does not match with type org.jfree.text.TextBlockAnchor of variable this.labelAnchor |
8 | Type org.jfree.chart.plot.PlotRenderingInfo of variable that.plotInfo does not match with type org.jfree.text.TextBlockAnchor of variable that.labelAnchor |
9 | Expression that.plotInfo cannot be parameterized, because it has dependencies to/from statements that will be extracted |
10 | Expression that.labelAnchor cannot be parameterized, because it has dependencies to/from statements that will be extracted |
11 | Type org.jfree.chart.plot.PlotRenderingInfo of variable that.plotInfo does not match with type org.jfree.text.TextBlockAnchor of variable that.labelAnchor |
12 | Not all possible execution flows end in a return statement |