Revision 43078 trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.geometry/org.gvsig.fmap.geometry.jts/src/main/java/org/gvsig/fmap/geom/jts/primitive/point/Point2D.java

View differences:

Point2D.java
240 240
        return builder.toString();
241 241
    }
242 242

  
243
    @Override
244
    public boolean equals(Object obj) {
245
        Point other;
246
        try {
247
            other = (Point) obj;
248
        } catch(ClassCastException e) {
249
            return false;
250
        }
251
        if( this.getGeometryType().getSubType() != other.getGeometryType().getSubType() ) {
252
            return false;
253
        }
254
        if( this.coordinate.x != other.getX() ) {
255
            return false;
256
        }
257
        if( this.coordinate.y != other.getY() ) {
258
            return false;
259
        }
260
        return true;
261
    }
262

  
263
    
243 264
}

Also available in: Unified diff