-
Basic internal initializer
Declaration
Swift
public convenience init( accessToken: String? = nil, locationProvider: LocationProvider? = DefaultLocationProvider() )
Parameters
accessToken
Mapbox Access Token to be used. Info.plist value for key
MGLMapboxAccessToken
will be used fornil
argumentlocationProvider
Provider configuration of LocationProvider that would grant location data by default
-
Search for places nearby the specified geographic point.
Declaration
Parameters
query
Search query
proximity
Geographic point to search nearby.
options
Search options
completion
Result of the search request, one of error or value.
-
Search for places nearby the specified geographic point.
Declaration
Swift
public func search( for query: Query, in region: BoundingBox, proximity: CLLocationCoordinate2D? = nil, options: Options = .init(), completion: @escaping (Swift.Result<[Result], Error>) -> Void )
Parameters
query
Search query
region
Limit results to only those contained within the supplied bounding box.
proximity
Optional geographic point to search nearby.
options
Search options
completion
Result of the search request, one of error or value.
-
Search for places nearby the specified geographic point.
Declaration
Swift
public func search( for query: Query, route: RouteOptions, options: Options = .init(), completion: @escaping (Swift.Result<[Result], Error>) -> Void )
Parameters
query
Search query
route
Route to search across (points and deviation options).
options
Search options
completion
Result of the search request, one of error or value.
-
Undocumented
See moreDeclaration
Swift
public struct Address
-
Undocumented
See moreDeclaration
Swift
public struct Options
-
Undocumented
See moreDeclaration
Swift
public struct Query
-
Undocumented
See moreDeclaration
Swift
public struct Result