TTSearchPolygon

@interface TTSearchPolygon : TTSearchShape

A polygon shape to be used for search query

  • Creates and returns a TTSearchPolygon object using coordinates array

    Declaration

    Objective-C

    + (TTSearchPolygon *_Nonnull)polygonWithCoordinates:
                                     (CLLocationCoordinate2D *_Nonnull)coordinates
                                                  count:(NSUInteger)count;

    Swift

    /*not inherited*/ init(coordinates: UnsafeMutablePointer<CLLocationCoordinate2D>, count: UInt)

    Parameters

    coordinates

    pointer to array of coordinates, array has to have at least 3 elements

    count

    number of coordiantes in array

    Return Value

    TTSearchPolygon

  • The array of coordinates defining the polygon.

    Declaration

    Objective-C

    @property (readonly, nonatomic) CLLocationCoordinate2D *_Nonnull coordinates;

    Swift

    var coordinates: UnsafeMutablePointer<CLLocationCoordinate2D> { get }
  • The number of items in the coordinates array.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) NSUInteger count;

    Swift

    var count: UInt { get }