GEOS 3.14.0dev
Public Member Functions | List of all members
geos::operation::relateng::RelatePointLocator Class Reference

#include <RelatePointLocator.h>

Public Member Functions

 RelatePointLocator (const Geometry *p_geom)
 
 RelatePointLocator (const Geometry *p_geom, bool p_isPrepared, const BoundaryNodeRule &p_bnRule)
 
void init (const Geometry *p_geom)
 
bool hasBoundary () const
 
void extractElements (const Geometry *geom)
 
void addPoint (const Point *pt)
 
void addLine (const LineString *line)
 
void addPolygonal (const Geometry *polygonal)
 
Location locate (const CoordinateXY *p)
 
int locateLineEndWithDim (const CoordinateXY *p)
 
Location locateNode (const CoordinateXY *p, const Geometry *parentPolygonal)
 
int locateNodeWithDim (const CoordinateXY *p, const Geometry *parentPolygonal)
 
int locateWithDim (const CoordinateXY *p)
 

Detailed Description

Locates a point on a geometry, including mixed-type collections. The dimension of the containing geometry element is also determined. GeometryCollections are handled with union semantics; i.e. the location of a point is that location of that point on the union of the elements of the collection.

Union semantics for GeometryCollections has the following behaviours:

Prepared mode is supported via cached spatial indexes.

Author
Martin Davis

Member Function Documentation

◆ locateNodeWithDim()

int geos::operation::relateng::RelatePointLocator::locateNodeWithDim ( const CoordinateXY *  p,
const Geometry parentPolygonal 
)

Locates a point which is known to be a node of the geometry, as a DimensionLocation.

Parameters
pthe point to locate
parentPolygonalthe polygon the point is a node of
Returns
the dimension and location of the point

◆ locateWithDim()

int geos::operation::relateng::RelatePointLocator::locateWithDim ( const CoordinateXY *  p)

Computes the topological location ( Location) of a single point in a Geometry, as well as the dimension of the geometry element the point is located in (if not in the Exterior). It handles both single-element and multi-element Geometries. The algorithm for multi-part Geometries takes into account the SFS Boundary Determination Rule.

Parameters
pthe point to locate
Returns
the Location of the point relative to the input Geometry

The documentation for this class was generated from the following file: