HybridReverseGeocoder
public final class HybridReverseGeocoder : ReverseGeocoder
Implementation of Reverse Geocoding API that wraps online and offline reverse geocoders. When online service is unavailable offline service is automatically used to improve availability.
Important
This is a Public Preview API. It may be changed or removed at any time.-
Creates a new
HybridReverseGeocoderinstance.Throws
An error ifNDSStoreis invalid.Important
This is a Public Preview API. It may be changed or removed at any time.Declaration
Swift
public convenience init( apiKey: String, store: NDSStore, timeout: Measurement<UnitDuration> = .tt.seconds(5), customAPIURL: URL? = nil ) throwsParameters
apiKeyA valid TomTom API Key.
storeNDSStore offline map handle. Additionally,
NDSStoredefines the overall geopolitical view for both online and offline inHybridSearch. Configure the corresponding geopolitical view inNDSStoreConfigurationand initializeNDSStorewith it.timeoutThe duration after which primary geocoder results are ignored and the fallback geocoder starts handling the query.
customAPIURLCustom base URL for online APIs. Defaults to nil and TomTom online API base URL will be used. Can be used to change to another service that implements the same API.
-
Reverse Geocoding API gives users a tool to translate a coordinate (for example: 37.786505, -122.3862) into a human-understandable street address, street element, or geography.
Important
This is a Public Preview API. It may be changed or removed at any time.Declaration
Swift
public func reverseGeocode( options: ReverseGeocoderOptions, completion: @escaping (Result<ReverseGeocoderResponse, Error>) -> () )Parameters
optionscompletionParameter completion: The completion closure is called after the response to the request has been processed. If no errors occurred,
ReverseGeocoderResponsecontains an array of categories and subcategories together with their translations and synonyms.
TomTom SDK for iOS (0.51.1)
HybridReverseGeocoder