SYContext Class Reference

Use this interface to set mandatory authentication credentials You have to set authentication credentials (Api key and App Secret code) in order to use the APIs contained within this SDK. Some APIs may appear to work without valid credentials but they may stop functioning in the near future when server side configurations change, so please obtain and use valid credentials. More...

#import <SYContext.h>

Inheritance diagram for SYContext:
Collaboration diagram for SYContext:

Class Methods

(void) + registerSharedInstanceClass:
 
(dispatch_once_t &) + mapLoaderSetupOnceToken
 
(void) + initWithConfiguration:withCompletion:
 Initializes Sygic SDK, must be called before any other sdk calls. More...
 
(void) + terminate
 Terminates Sygic SDK. More...
 
(BOOL) + isInitialized
 Check if Sygic SDK is initialized. More...
 
(nonnull NSString *) + sdkVersion
 

Detailed Description

Use this interface to set mandatory authentication credentials You have to set authentication credentials (Api key and App Secret code) in order to use the APIs contained within this SDK. Some APIs may appear to work without valid credentials but they may stop functioning in the near future when server side configurations change, so please obtain and use valid credentials.

Method Documentation

◆ initWithConfiguration:withCompletion:()

+ (void) initWithConfiguration: (nonnull NSDictionary *)  configuration
withCompletion: (nullable void(^)(SYContexInitResult result, NSString *_Nonnull description))  completion 

Initializes Sygic SDK, must be called before any other sdk calls.

Parameters
appKeyApplication Key
appSecretApplication Secret code
completionInitialization completion block Sets the mandatory Sygic Authentication Credentials and License Key.

These credentials MUST be set once before attempting to use any other APIs in the Sygic SDK. You may only call this method once. It is recommended to call this method in [UIApplicationDelegate didFinishLaunchingWithOptions].

Initializes Sygic SDK, must be called before any other sdk calls

Parameters
configurationConfiguration data, you can find complete configuration scheme here .... Simple example: NSDictionary* config ="Authentication": @"app_key" : @"your-app-key", @"app_secret" : @"your-app-secret"} };
completionInitialization completion block

These credentials MUST be set once before attempting to use any other APIs in the Sygic SDK. You may only call this method once. It is recommended to call this method in [UIApplicationDelegate didFinishLaunchingWithOptions].

◆ isInitialized()

+ (BOOL) isInitialized

Check if Sygic SDK is initialized.

Returns
YES if Sygic SDK is initialized, otherwise NO. If NO is returned then the Sygic SDK is not ready to handle any service.

◆ mapLoaderSetupOnceToken()

+ (dispatch_once_t&) mapLoaderSetupOnceToken

Provided by category SYContext(SharedInstances).

◆ registerSharedInstanceClass:()

+ (void) registerSharedInstanceClass: (Class)  c

Provided by category SYContext(SharedInstances).

◆ sdkVersion()

+ (nonnull NSString*) sdkVersion

SDK version in format MAJOR.MINOR.PATCH.

◆ terminate()

+ (void) terminate

Terminates Sygic SDK.


The documentation for this class was generated from the following file: