Class RectangleContains

Hierarchy: Object , RectangleContains
public class RectangleContains
Optimized implementation of the contains spatial predicate for cases where the first Geometry is a rectangle. This class works for all input geometries, including GeometryCollections.

As a further optimization, this class can be used to test many geometries against a single rectangle in a slightly more efficient way.

Other

  • version: 1.7
public RectangleContains(Polygon rectangle)
Create a new contains computer for two geometries.
Parameters:
rectangle - rectangle a rectangular geometry
public static boolean contains(Polygon rectangle, Geometry b)
Tests whether a rectangle contains a given geometry.
Parameters:
rectangle - rectangle a rectangular Polygon
b - b a Geometry of any type
Returns:
true if the geometries intersect
public boolean contains(Geometry geom)