isWithinBoundaries
public boolean isWithinBoundaries(java.awt.geom.Point2D pointToCheck)
Method to check whether a point lies within the boundaries of the spatial model.
A point lies within the space described by the RectangularSpatialModel when it lies within a rectangular
box of given width and height around the centered coordinates (i.e. x in [longitudeCentred - width/2.0, longitudeCentred + width/2.0]
and y in [latitudeCentred - height/2.0,latitudeCentred + height/2.0].
- Overrides:
isWithinBoundaries
in class RectangularSpatialModel
- Parameters:
pointToCheck
- The coordinates to check the box with
- Returns:
- true if the point lies within the box (including corners), false otherwise