Overview | Package | Class | Tree | Deprecated | Index | Help
| JTS Topology Suite - v 1.12
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.vividsolutions.jts.operation.predicate
Class RectangleIntersects

    java.lang.Object
      com.vividsolutions.jts.operation.predicate.RectangleIntersects

    public class RectangleIntersects

extends java.lang.Object

Optimized implementation of the `intersects` spatial predicate for cases where one `Geometry` is a rectangle. This class works for all input geometries, including `GeometryCollection`s.

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

Version:
  1.7

Constructor Summary
`RectangleIntersects(Polygon rectangle)` Create a new intersects computer for a rectangle.

Method Summary
`boolean` | `intersects(Geometry geom)`
`static boolean` | `intersects(Polygon rectangle, Geometry b)` Tests whether a rectangle intersects a given geometry.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### RectangleIntersects

    public RectangleIntersects(Polygon rectangle)

  Create a new intersects computer for a rectangle.

  Parameters:
    `rectangle` - a rectangular geometry

Method Detail

### intersects

    public static boolean intersects(Polygon rectangle,
                                     Geometry b)

  Tests whether a rectangle intersects a given geometry.

  Parameters:
    `rectangle` - a rectangular Polygon
    `b` - a Geometry of any type
  Returns:
    true if the geometries intersect

### intersects

    public boolean intersects(Geometry geom)

Overview | Package | Class | Tree | Deprecated | Index | Help
| JTS Topology Suite - v 1.12
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD