Because the Object API clearly states that hashCode and equals must be synced (when equals returns true, hashCodes must be equal as well). If they are not the behavior of several standard classes is...
Type: Posts; User: Cornix
Because the Object API clearly states that hashCode and equals must be synced (when equals returns true, hashCodes must be equal as well). If they are not the behavior of several standard classes is...
I just want to point out, that this line:
if ((p1.compareToXY(diagPoint) == 0) || (p1.compareToXY(diagPoint) == 0))
does not look quite right since you are checking for the very same thing twice....