public boolean equalsExact(Geometry other, double tolerance) { if (!isEquivalentClass(other)) { return false; } if (isEmpty() && other.isEmpty()) { return true; } if (isEmpty() != other.isEmpty()) { return false; } return equal(((Point) other).getCoordinate(), this.getCoordinate(), tolerance); }