Class SpatialBoundary
- Namespace
- YndigoBlue.Velocity.Functions
- Assembly
- YndigoBlue.Velocity.dll
Represents the ST_Boundary spatial analysis function that returns the boundary of a geometry.
public class SpatialBoundary : Function, IElement, ICheckItem, IDefaultItem, IFilterItem
- Inheritance
-
SpatialBoundary
- Implements
Remarks
Warning
Spatial functions are not available in the Community Edition of Velocity. They require the Full Edition.
The ST_Boundary function returns a geometry representing the boundary of the input spatial object according to the OGC SFS specification. For polygons, returns the rings (exterior and interior) as a LINESTRING or MULTILINESTRING. For linestrings, returns the endpoints as a MULTIPOINT (empty if closed). For points, returns an empty geometry collection. The boundary is the set of points that form the closure of the geometry minus its interior. Useful for topological analysis, finding edges, or geometric computations. OGC-compliant.
Return Types by Input:
| Input Type | Boundary Result |
|---|---|
| POLYGON | LINESTRING (the exterior ring) |
| POLYGON with holes | MULTILINESTRING (exterior + interior rings) |
| LINESTRING (open) | MULTIPOINT (the two endpoints) |
| LINESTRING (closed) | EMPTY (start = end, no boundary) |
| POINT | EMPTY (points have no boundary) |
| MULTIPOLYGON | MULTILINESTRING (all rings) |
Example Results (using test geometries):
| Shape | Boundary |
|---|---|
| PY0 (4°×4° square) | LINESTRING (4 vertices) |
| PY1 (0.5°×1° rectangle) | LINESTRING (exterior ring) |
| PY2 (1°×3° rectangle) | LINESTRING (exterior ring) |
| PY3 (triangle) | LINESTRING (3 vertices) |
| PY4 (2°×1.5° rectangle) | LINESTRING (exterior ring) |
| LN1 (linestring) | MULTIPOINT (2 endpoints) |
| PT1, PT2 (points) | EMPTY |
Constructors
- SpatialBoundary(Geometry)
Initializes a new instance of ST_Boundary with a geometry literal.
- SpatialBoundary(Column)
Initializes a new instance of ST_Boundary with a spatial column.
- SpatialBoundary(Function)
Initializes a new instance of ST_Boundary for a function result.
- SpatialBoundary(Geography)
Initializes a new instance of ST_Boundary with a geography literal.