MBXGeometry

extension MBXGeometry
  • Initialize a MBXGeometry point from a coordinate.

    Declaration

    Swift

    public convenience init(coordinate: CLLocationCoordinate2D)

    Parameters

    coordinate

    The coordinate to represent the MBXGeometry point.

  • Initialize a MBXGeometry line from an array of coordinates.

    Declaration

    Swift

    public convenience init(line coordinates: [CLLocationCoordinate2D])

    Parameters

    coordinates

    The coordinates to represent the MBXGeometry line.

  • Initialize a MBXGeometry polygon from a two-dimensional array of coordinates.

    Declaration

    Swift

    public convenience init(polygon coordinates: [[CLLocationCoordinate2D]])

    Parameters

    coordinates

    The coordinates to represent the MBXGeometry polygon.

  • Initialize a MBXGeometry multipoint from an array of CLLocationCoordinates.

    Declaration

    Swift

    public convenience init(multiPoint coordinates: [CLLocationCoordinate2D])

    Parameters

    coordinates

    The coordinates to represent the MBXGeometry multipoint.

  • Initialize a MBXGeometry multiline from a two-dimensional array of CLLocationCoordinates.

    Declaration

    Swift

    public convenience init(multiLine coordinates: [[CLLocationCoordinate2D]])

    Parameters

    coordinates

    The coordinates to represent the MBXGeometry multiline.

  • Initialize a MBXGeometry multipolygon from a three-dimensional array of CLLocationCoordinates.

    Declaration

    Swift

    public convenience init(multiPolygon coordinates: [[[CLLocationCoordinate2D]]])

    Parameters

    coordinates

    The coordinates to represent the MBXGeometry multipolygon.

  • Allows an MBXGeometry object to be initialized with an turf Geometry object.

    Declaration

    Swift

    public convenience init(geometry: Geometry)

    Parameters

    geometry

    The turf Geometry object to transform into the MBXGeometry type.