geoPolygon.php
Table of Contents
Functions
- geoPolygon() : string
- Build a GeoJSON Polygon geometry.
Functions
geoPolygon()
Build a GeoJSON Polygon geometry.
geoPolygon(array<string|int, mixed>|string $points) : string
This helper wraps the ArangoDB AQL function GEO_POLYGON(points) which
constructs a valid GeoJSON Polygon. The outer ring (and any holes) is an
array of linear rings, each a closed list of [longitude, latitude] pairs
(first and last coordinate must be equal). Coordinates must already follow
the GeoJSON longitude-first convention.
Example AQL usage:
GEO_POLYGON([ [ [0,0], [1,0], [1,1], [0,1], [0,0] ] ])
Parameters
- $points : array<string|int, mixed>|string
-
An array of linear rings, or an AQL expression.
Tags
Return values
string —The formatted AQL expression.