Polygon
A Polygon geometry represents a surface in coordinate space bounded by linear rings.
To specify a constraint specific to Polygon objects, it is useful to introduce the concept of a linear ring:
A linear ring is a closed LineString with four or more Position objects.
The first and last Position objects are equivalent, and they MUST contain identical values; their representation SHOULD also be identical.
A linear ring is the boundary of a surface or the boundary of a hole in a surface.
A linear ring MUST follow the right-hand rule with respect to the area it bounds, i.e., exterior rings are counterclockwise, and holes are clockwise.
See RFC 7946 Section 3.1.6 for the full specification.
See also
Throws
if the coordinates are empty or any of the Position lists representing a LineString is either not closed or contains fewer than 4 Position objects.
Constructors
Create a Polygon by a number of linear rings.
Create a Polygon by a number of closed LineString objects.
Create a Polygon by arrays (= polygon rings) of arrays (= Position objects) where each Position is represented by a DoubleArray.