SENTOptions

Wrapper class of options while Initializing the SDK

platformURL

The Sentiance platform URL. Use this only if you are migrating from an older SDK version (5.x)

@property (nonatomic, copy, nullable) NSString *platformUrl;

isAppSessionDataCollectionAllowed

Informs whether app session data collection is enabled.

If enabled, the SDK may collect additional sensor and location data when the app is in the foreground (i.e visible to the user). This data may get uploaded to the Sentiance Platform.

@property (nonatomic) BOOL isAppSessionDataCollectionAllowed;

registerBackgroundTaskIdentifiers

Set to NO to prevent the SDK from registering its own background task identifiers during initialization.

By default, this is set to YES. You should set it to NO only when initializing the SDK outside of your app delegate’s application:didFinishLaunchingWithOptions:launchOptions: method, as registering tasks outside of this method can cause iOS to terminate your app.

appCrashedOnPreviousLaunch

This value is supplied when initializing an instance of SENTOptions. A boolean value of true indicates that the app crashed during its previous lifecycle, while a value of false indicates that it did not. If no value was set during SENTOptions initialization, this property will be nil.

@property (nonatomic, strong, readonly, nullable) NSNumber *appCrashedOnPreviousLaunch;

initFor:initPurpose:

Returns a SENTOptions object that is used when initializing the SDK

Parameter

initPurpose

The purpose for which the SENTOptions object is being created. When initializing the SDK during app launch from within the app delegate, specify SENTOptionsInitPurposeAppLaunch. When initializing the SDK outside of the app delegate, use SENTOptionsInitPurposeDelayedSdkInitialization. The latter will make sure that the SDK initialization skips certain actions that should only be done during app startup (e.g. registering background task identifiers).

initFor:initPurpose :appCrashedOnPreviousLaunch;

Returns a SENTOptions object that is used when initializing the SDK

Parameter

initPurpose

The purpose for which the SENTOptions object is being created. When initializing the SDK during app launch from within the app delegate, specify SENTOptionsInitPurposeAppLaunch. When initializing the SDK outside of the app delegate, use SENTOptionsInitPurposeDelayedSdkInitialization. The latter will make sure that the SDK initialization skips certain actions that should only be done during app startup (e.g. registering background task identifiers).

appCrashedOnPreviousLaunch

Indicates whether the app crashed during its previous lifecycle. If you monitor crashes, for example using a third party crash reporting library, you can pass the crash status through this parameter. The Sentiance SDK uses this information to detect instability during startup and may take appropriate measures to stabilize the situation.

Last updated