Polygon class
A GeoJSON Polygon object - a JSON object that represents a geographic polygon. The full description is detailed in RFC 7946.
Constructors
Polygon(Position[][] | Position[], Bounding |
Constructs a Polygon. |
Properties
bbox | The bounding box of the polygon. |
coordinates | The array of linear ring coordinate arrays defining the polygon. |
type | A GeoJSON type descriptor with value "Polygon". |
TYPE | A static GeoJSON type descriptor for the Polygon class to be used in runtime comparisons. |
Constructor Details
Polygon(Position[][] | Position[], BoundingBox)
Constructs a Polygon.
new Polygon(coordinates: Position[][] | Position[], bbox?: BoundingBox)
Parameters
The array of linear ring coordinate arrays defining the polygon.
- bbox
- BoundingBox
The bounding box of the polygon.
Property Details
bbox
coordinates
The array of linear ring coordinate arrays defining the polygon.
coordinates: Position[][]
Property Value
Position[][]
type
A GeoJSON type descriptor with value "Polygon".
type: string
Property Value
string
TYPE
A static GeoJSON type descriptor for the Polygon class to be used in runtime comparisons.
static TYPE: string
Property Value
string