3. Initialization
SDK Initialization Steps
1. Initialize in the AppDelegate Class
class AppDelegate: NSObject, UIApplicationDelegate {
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool {
return true
}
}2. Import the SDK in your source file.
@import SENTSDK;3. Initialize the SDK
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey : Any]? = nil) -> Bool {
let result = Sentiance.shared.initialize(options: SENTOptions(for: .appLaunch))
if result.isSuccessful {
NSLog("Initialization succeeded")
}
return true
}Last updated