Polygon

open class Polygon : Codable, GeoJsonObject

NOTE: This file implements a small portion of the RFC7946 that is used in the coaty framework. This implementation is by no means complete. Many trivial choices were made during development. In case more compliance with the standard is needed, further development of this class is necessary. Polygon geometry object as defined in: https://tools.ietf.org/html/rfc7946#section-3.1.6

  • Specifies the type of GeoJSON object.

    Declaration

    Swift

    public var type: GeoJsonType
  • Bounding box of the coordinate range of the object’s Geometries, Features, or Feature Collections. The value of the bbox member is an array of length 2*n where n is the number of dimensions represented in the contained geometries, with all axes of the most southwesterly point followed by all axes of the more northeasterly point. The axes order of a bbox follows the axes order of geometries. https://tools.ietf.org/html/rfc7946#section-5

    Declaration

    Swift

    public var bbox: BBox?
  • For type “Polygon”, the “coordinates” member MUST be an array of linear ring coordinate arrays.

    Declaration

    Swift

    public var coordinates: [[Position]]
  • Undocumented

    Declaration

    Swift

    public init(coordinates: [[Position]])