FindBug warning: EQ_SELF_USE_OBJECT: class defines equals(Region) and uses Object.equals(Object)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1716004 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
d6ee7f8221
commit
cba32cd1a0
@ -159,12 +159,19 @@ public class Region implements Comparable<Region> {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (this instanceof Region)
|
||||
return equals((Region) o);
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
public boolean equals(Region r)
|
||||
{
|
||||
return (compareTo(r) == 0);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public int hashCode() {
|
||||
assert false : "hashCode not designed";
|
||||
|
Loading…
Reference in New Issue
Block a user