Package org.locationtech.jts.geom.prep
Class PreparedPolygonPredicate
java.lang.Object
org.locationtech.jts.geom.prep.PreparedPolygonPredicate
- Direct Known Subclasses:
AbstractPreparedPolygonContains
,PreparedPolygonContainsProperly
,PreparedPolygonIntersects
A base class for predicate operations on
PreparedPolygon
s.-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPreparedPolygonPredicate
(PreparedPolygon prepPoly) Creates an instance of this operation. -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
isAllTestComponentsInTarget
(Geometry testGeom) Tests whether all components of the test Geometry are contained in the target geometry.protected boolean
isAllTestComponentsInTargetInterior
(Geometry testGeom) Tests whether all components of the test Geometry are contained in the interior of the target geometry.protected boolean
isAnyTargetComponentInAreaTest
(Geometry testGeom, List targetRepPts) Tests whether any component of the target geometry intersects the test geometry (which must be an areal geometry)protected boolean
isAnyTestComponentInTarget
(Geometry testGeom) Tests whether any component of the test Geometry intersects the area of the target geometry.protected boolean
isAnyTestComponentInTargetInterior
(Geometry testGeom) Tests whether any component of the test Geometry intersects the interior of the target geometry.
-
Field Details
-
prepPoly
-
targetPointLocator
-
-
Constructor Details
-
PreparedPolygonPredicate
Creates an instance of this operation.- Parameters:
prepPoly
- the PreparedPolygon to evaluate
-
-
Method Details
-
isAllTestComponentsInTarget
Tests whether all components of the test Geometry are contained in the target geometry. Handles both linear and point components.- Parameters:
geom
- a geometry to test- Returns:
- true if all components of the argument are contained in the target geometry
-
isAllTestComponentsInTargetInterior
Tests whether all components of the test Geometry are contained in the interior of the target geometry. Handles both linear and point components.- Parameters:
geom
- a geometry to test- Returns:
- true if all components of the argument are contained in the target geometry interior
-
isAnyTestComponentInTarget
Tests whether any component of the test Geometry intersects the area of the target geometry. Handles test geometries with both linear and point components.- Parameters:
geom
- a geometry to test- Returns:
- true if any component of the argument intersects the prepared area geometry
-
isAnyTestComponentInTargetInterior
Tests whether any component of the test Geometry intersects the interior of the target geometry. Handles test geometries with both linear and point components.- Parameters:
geom
- a geometry to test- Returns:
- true if any component of the argument intersects the prepared area geometry interior
-
isAnyTargetComponentInAreaTest
Tests whether any component of the target geometry intersects the test geometry (which must be an areal geometry)- Parameters:
geom
- the test geometryrepPts
- the representative points of the target geometry- Returns:
- true if any component intersects the areal test geometry
-