Builder
Last updated
Last updated
This class is used with Sentiance.init(SdkConfig, OnInitCallback)
.
Builder
Creates a builder object used for initializing the Sentiance SDK.
Please note: hard-coded credentials are not secure. Load your Sentiance credentials from a secure source such a remote server, and store them securely on the device.
Parameters | |
---|---|
baseURL()
Sets the Sentiance API URL.
Parameters | |
---|---|
build()
Builds an
SdkConfig
object.
setMetaUserLinker
This method was replaced by setUserLinker(UserLinker) in v6.0.0.
Sentiance assigns to each user a unique ID. You can link your app's user to the Sentiance user using meta-user linking. The linking step involves server-to-server communication, and is triggered by the SDK via this meta-user linking callback.
Learn more about Meta-User linking here.
setMetaUserLinker
This method was replaced by setUserLinker(UserLinkerAsync) in v6.0.0.
Same as
setMetaUserLinker(MetaUserLinker)
but accepts an async linker instead.
setNotificationId
The default notification ID used by the SDK when starting a service is 2123874432. If your app already shows a persistent notification when running, you can pass your existing notification ID and have a single notification show up in the panel.
setOnSdkStatusUpdateHandler
At runtime, the SDK will occasionally send status updates to your app. These are concerning the detection status and environment changes (e.g. location availability, device configuration changes, etc.). You can set a handler here to capture these updates.
setTriggeredTripsEnabled
Enables triggered trips mode on the SDK.
Learn more about triggered trips here.
setUserLinker
Sentiance assigns to each user a unique ID. You can link your app's user to the Sentiance user using user linking. The linking step involves server-to-server communication, and is triggered by the SDK via this user linking callback.
Learn more about user linking here.
setUserLinker
Same as
setUserLinker(UserLinker)
but accepts an async linker instead.
Parameters | |
---|---|
Parameters | |
---|---|
Parameters | |
---|---|
Parameters | |
---|---|
Parameters | |
---|---|
Parameters | |
---|---|
Parameters | |
---|---|
Parameters | |
---|---|
appId
The Sentiance app credential ID.
secret
The Sentiance app credential secret.
notification
A Notification
used by the SDK when starting a foreground service.
url
The Sentiance API URL.
id
The ID used when starting a foreground service.
linker
A MetaUserLinker
which will handle the linking.
linker
A MetaUserLinkerAsync
which will handle the linking.
id
The ID used when starting a foreground service.
handler
The OnSdkStatusUpdateHandler
which will receive SdkStatus
updates.
enabled
true
to enable triggered trips.
linker
A UserLinker
which will handle the linking.
linker
A UserLinkerAsync
which will handle the linking.