SearchConfig

open class SearchConfig: NSObject

Encapsulates request parameters for search requests.

  • Text to search for within components of the location. This value is required.

    Declaration

    Swift

    public var searchText: String
  • The number of results to return. This value is optional and defaults to 10.

    Declaration

    Swift

    public var numberOfResults: Int?
  • The boundary country (in ISO-3166 alpha-2 or alpha-3 format) to limit results by. This value is optional and defaults to not restricting results to any country.

    Declaration

    Swift

    public var boundaryCountry: String?
  • The rectangular boundary to limit results to. This value is optional and defaults to none.

    Declaration

    Swift

    public var boundaryRect: SearchRect?
  • The circular boundary to limit results to. This value is optional and defaults to none.

    Declaration

    Swift

    public var boundaryCircle: SearchCircle?
  • The point to order results by where results closer to this value are returned higher in the list. This value is optional and defaults to none.

    Declaration

    Swift

    public var focusPoint: GeoPoint?
  • Sources to fetch data from. This value is optional and defaults to all sources.

    Declaration

    Swift

    public var dataSources: [SearchSource]?
  • Layers to fetch sources from. This value is optional and defaults to all sources.

    Declaration

    Swift

    public var layers: [LayerFilter]?
  • Initialize a search config with all the required parameters. This value will get converted into the appropriate query item.

    Declaration

    Swift

    public init(searchText: String, completionHandler: @escaping (SearchResponse) -> Void)

    Parameters

    searchText

    Text to search for within components of the location.

    completionHandler

    The closure to execute when the request suceeds or fails.