MSFValhallaOnlineRoutingService
Objective-C
@interface MSFValhallaOnlineRoutingService : MSFRoutingService
Swift
class MSFValhallaOnlineRoutingService : MSFRoutingService
An online routing service using a (MapBox) Valhalla service, provided “as-is”: check the provider’s terms. Routing and route matching make network requests and must run on a non-UI background thread. Note: this class is experimental and may change or even be removed in future SDK versions.
-
Constructs a new ValhallaOnlineRoutingService instance given an API key.
Declaration
Objective-C
- (id)initWithApiKey:(NSString *)apiKey;Swift
init!(apiKey: String!)Parameters
apiKeyThe API key (access token) to use registered with MapBox.
-
Undocumented
Declaration
Objective-C
- (id)init;Swift
init!() -
Returns the custom backend service URL.
Declaration
Objective-C
- (NSString *)getCustomServiceURL;Swift
func getCustomServiceURL() -> String!Return Value
The custom backend service URL. If this is not defined, an empty string is returned.
-
Sets the custom backend service URL. The tag “{service}” is substituted with the service type (“route” or “trace_route”), the optional tag “{api_key}” with the API key.
Declaration
Objective-C
- (void)setCustomServiceURL:(NSString *)serviceURL;Swift
func setCustomServiceURL(_ serviceURL: String!)Parameters
serviceURLThe custom backend service URL to use. If this is empty, then the default service is used.
-
Returns the current timeout value.
Declaration
Objective-C
- (int)getTimeout;Swift
func getTimeout() -> Int32Return Value
The current timeout value in seconds. If negative, then default platform-specific timeout is used.
-
Sets the current timeout value.
Declaration
Objective-C
- (void)setTimeout:(int)timeout;Swift
func setTimeout(_ timeout: Int32)Parameters
timeoutThe new timeout value in seconds. If negative, then default platform-specific timeout is used.
-
Returns the current set of HTTP headers used. Initially this set is empty and can be changed with setHTTPHeaders.
Declaration
Objective-C
- (MSFStringMap *)getHTTPHeaders;Swift
func getHTTPHeaders() -> MSFStringMap!Return Value
The current set of custom HTTP headers.
-
Sets HTTP headers for all subsequent requests.
Declaration
Objective-C
- (void)setHTTPHeaders:(MSFStringMap *)headers;Swift
func setHTTPHeaders(_ headers: MSFStringMap!)Parameters
headersA map of HTTP headers that will be used in subsequent requests.
-
Undocumented
Declaration
Objective-C
- (NSString *)getProfile;Swift
func getProfile() -> String! -
Undocumented
Declaration
Objective-C
-(NSString*)getProfileSwigExplicitMSFValhallaOnlineRoutingService;Swift
func getProfileSwigExplicitMSFValhallaOnlineRoutingService() -> String! -
Undocumented
Declaration
Objective-C
- (void)setProfile:(NSString *)profile;Swift
func setProfile(_ profile: String!) -
Undocumented
Declaration
Objective-C
-(void)setProfileSwigExplicitMSFValhallaOnlineRoutingService: (NSString*)profile;Swift
func setProfileSwigExplicit(_ profile: String!) -
Undocumented
Declaration
Objective-C
- (MSFRouteMatchingResult *)matchRoute:(MSFRouteMatchingRequest *)request;Swift
func matchRoute(_ request: MSFRouteMatchingRequest!) -> MSFRouteMatchingResult! -
Undocumented
Declaration
Objective-C
-(MSFRouteMatchingResult*)matchRouteSwigExplicitMSFValhallaOnlineRoutingService: (MSFRouteMatchingRequest*)request;Swift
func matchRouteSwigExplicitMSFValhallaOnlineRoutingService(_ request: MSFRouteMatchingRequest!) -> MSFRouteMatchingResult! -
Undocumented
Declaration
Objective-C
- (MSFRoutingResult *)calculateRoute:(MSFRoutingRequest *)request;Swift
func calculateRoute(_ request: MSFRoutingRequest!) -> MSFRoutingResult! -
Undocumented
Declaration
Objective-C
-(MSFRoutingResult*)calculateRouteSwigExplicitMSFValhallaOnlineRoutingService: (MSFRoutingRequest*)request;Swift
func calculateRouteSwigExplicitMSFValhallaOnlineRoutingService(_ request: MSFRoutingRequest!) -> MSFRoutingResult! -
Undocumented
Declaration
Objective-C
-(void)dealloc;Swift
func dealloc()