CategoryTick that = (CategoryTick) obj;
if (!ObjectUtilities.equal(this.category, that.category)) {
return false;
}
if (!ObjectUtilities.equal(this.label, that.label)) {
return false;
}
if (!ObjectUtilities.equal(this.labelAnchor, that.labelAnchor)) {
return false;
}
return true;
if (obj instanceof SubCategoryAxis && super.equals(obj)) {
SubCategoryAxis axis = (SubCategoryAxis) obj;
if (!this.subCategories.equals(axis.subCategories)) {
return false;
}
if (!this.subLabelFont.equals(axis.subLabelFont)) {
return false;
}
if (!this.subLabelPaint.equals(axis.subLabelPaint)) {
return false;
}
return true;
}
Clone fragments detected by clone detection tool
File path: /jfreechart-1.0.10/src/org/jfree/chart/axis/CategoryTick.java
|
|
File path: /jfreechart-1.0.10/src/org/jfree/chart/axis/SubCategoryAxis.java
|
Method name: boolean equals(Object)
|
|
Method name: boolean equals(Object)
|
Number of AST nodes: 8
|
|
Number of AST nodes: 9
|
|
1 | CategoryTick that↵ | | 1 | if (obj instanceof SubCategoryAxis && super.equals(obj)) {↵
|
2 | = (CategoryTick) obj; ↵ | | 2 | SubCategoryAxis axis = (SubCategoryAxis) obj;↵
|
3 | if (!ObjectUtilities.equal(this.category, that.category)) {↵ | | 3 | if (!this.subCategories.equals(axis.subCategories)) {↵
|
4 | return false; ↵ | | 4 | return false;↵
|
5 | }↵ | | 5 | }↵
|
6 | if (!ObjectUtilities.equal(this.label, that.label)) {↵ | | 6 | if (!this.subLabelFont.equals(axis.subLabelFont)) {↵
|
7 | return false; ↵ | | 7 | return false; ↵
|
8 | }↵ | | 8 | }↵
|
9 | if (!ObjectUtilities.equal(this.labelAnchor, that.labelAnchor)) {↵ | | 9 | if (!this.subLabelPaint.equals(axis.subLabelPaint)) {↵
|
10 | return false; ↵ | | 10 | return false; ↵
|
11 | }↵ | | 11 | }↵
|
12 | return true; | | 12 | return true;↵
|
| | | 13 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 1.0 |
Clones location | Clones are in different classes |
Number of node comparisons | 9 |