File path: /jfreechart-1.0.10/src/org/jfree/chart/axis/Tick.java | File path: /jfreechart-1.0.10/src/org/jfree/chart/labels/MultipleXYSeriesLabelGenerator.java | |||
Method name: boolean equals(Object)
|
Method name: boolean equals(Object)
|
|||
Number of AST nodes: 10 | Number of AST nodes: 12 | |||
1 | Tick t = (Tick) obj; ↵ | 1 | if (obj == this) {↵ | |
2 | return true;↵ | |||
2 | ↵ | 3 | }↵ | |
3 | if (!ObjectUtilities.equal(this.text, t.text)) {↵ | 4 | if (!(obj instanceof MultipleXYSeriesLabelGenerator)) {↵ | |
4 | return false; ↵ | 5 | return false;↵ | |
5 | }↵ | 6 | }↵ | |
7 | MultipleXYSeriesLabelGenerator that ↵ | |||
6 | if (!ObjectUtilities.equal(this.textAnchor, t.textAnchor↵ | 8 | = (MultipleXYSeriesLabelGenerator) obj;↵ | |
7 | )) {↵ | 9 | if (!this.formatPattern.equals(that.formatPattern)) {↵ | |
8 | return false; ↵ | 10 | return false;↵ | |
9 | }↵ | 11 | ↵ | |
10 | ↵ | 12 | }↵ | |
11 | if (!ObjectUtilities.equal(this.rotationAnchor, t.rotationAnchor↵ | 13 | if (!this.additionalFormatPattern.equals(↵ | |
12 | )) {↵ | 14 | that.additionalFormatPattern)) {↵ | |
13 | return false; ↵ | 15 | return false;↵ | |
14 | ↵ | |||
15 | }↵ | 16 | }↵ | |
16 | if (!(this.angle == t.angle)) {↵ | 17 | if (!this.seriesLabelLists.equals(that.seriesLabelLists)) {↵ | |
17 | return false; ↵ | 18 | return false;↵ | |
18 | ↵ | |||
19 | }↵ | 19 | }↵ | |
20 | return true; | 20 |
| |
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) | 1.3 |
Clones location | Clones are in different classes |
Number of node comparisons | 54 |
Number of mapped statements | 9 |
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) | 4.8 |
Clone type | Type 2 |
ID | Statement | ID | Statement | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4 | Tick t = (Tick)obj; | | ||||||||||||||
5 | if (!ObjectUtilities.equal(this.text, t.text)) |
| 3 | if (!(obj instanceof MultipleXYSeriesLabelGenerator)) | ||||||||||||
6 | return false; | 4 | return false; | |||||||||||||
| 5 | MultipleXYSeriesLabelGenerator that = (MultipleXYSeriesLabelGenerator)obj; | ||||||||||||||
7 | if (!ObjectUtilities.equal(this.textAnchor, t.textAnchor)) |
| 6 | if (!this.formatPattern.equals(that.formatPattern)) | ||||||||||||
8 | return false; | 7 | return false; | |||||||||||||
9 | if (!ObjectUtilities.equal(this.rotationAnchor, t.rotationAnchor)) |
| 8 | if (!this.additionalFormatPattern.equals(that.additionalFormatPattern)) | ||||||||||||
10 | return false; | 9 | return false; | |||||||||||||
11 | if (!(this.angle == t.angle)) |
| 10 | if (!this.seriesLabelLists.equals(that.seriesLabelLists)) | ||||||||||||
12 | return false; | 11 | return false; | |||||||||||||
13 | return true; | 12 | return true; |
Row | Violation |
---|---|
1 | Expression ObjectUtilities.equal(this.text,t.text) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
2 | Expression ObjectUtilities.equal(this.textAnchor,t.textAnchor) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
3 | Expression this.formatPattern.equals(that.formatPattern) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
4 | Expression ObjectUtilities.equal(this.rotationAnchor,t.rotationAnchor) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
5 | Expression this.additionalFormatPattern.equals(that.additionalFormatPattern) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
6 | Expression (this.angle == t.angle) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
7 | Expression this.seriesLabelLists.equals(that.seriesLabelLists) cannot be parameterized, because it has dependencies to/from statements that will be extracted |
8 | Not all possible execution flows end in a return statement |