Class SpatialPredicates
Static spatial predicates shared by every tool that accepts a GeoQuery. All predicates operate in planar lat/lon space and treat bounding-box edges as inclusive.
public static class SpatialPredicates
- Inheritance
-
SpatialPredicates
- Inherited Members
Methods
Contains(BoundingBox, GeoPoint)
Returns true when box contains
point. Used by point-style queries where the
query bbox collapses to the point itself.
public static bool Contains(BoundingBox box, GeoPoint point)
Parameters
boxBoundingBoxpointGeoPoint
Returns
ContainsPoint(IReadOnlyList<GeoPoint>, GeoPoint)
Returns true when point lies inside
the polygon ring, using a planar ray-casting
test. Points on the ring boundary are reported as inside.
public static bool ContainsPoint(IReadOnlyList<GeoPoint> ring, GeoPoint point)
Parameters
ringIReadOnlyList<GeoPoint>pointGeoPoint
Returns
Intersects(BoundingBox, GeoQuery)
Returns true when box intersects (or
touches) query's coarse bounding box.
public static bool Intersects(BoundingBox box, GeoQuery query)
Parameters
boxBoundingBoxqueryGeoQuery
Returns
Remarks
A GeoQuery.Polyline is tested segment by segment:
box must touch the bounding box of at least one
segment, inflated by the corridor half-width. Testing against the
envelope of every vertex instead would match anything inside the
route's overall extent — kilometres off a bending track — whatever
the corridor width.