AshNeo4j.Functions.StIntersects (AshNeo4j v0.8.1)

Copy Markdown View Source

st_intersects(a, b) — true if two geometries share any space. Mirrors ash_geo / PostGIS ST_Intersects. Exact, via topo on the %Geo.*{} geometries (#267) — handles any combination of Point / LineString / Polygon / Multi* directly, including segment-edge crossings.

Place
|> Ash.Query.filter(st_intersects(bounds, ^other_polygon))
|> Ash.read!()

Evaluates in memory. Unlike st_contains, st_intersects is not pushed down — a bbox-overlap prefilter via the bbSW/bbNE companions is tractable (point.withinBBox on the corners) but deferred to a follow-up. In-memory topo is correct and fast at NBN scale.

Notably, a LineString that crosses a Polygon without a vertex inside it now correctly intersects (the old vertex-in-bbox approximation missed that case).

Summary

Functions

args()

Callback implementation for Ash.Query.Function.args/0.

has_partial_evaluate?()