Get SDK Information
The GetInformation Event is used to obtain all the required information for the SDK which the client is using. You can find SDK Information related events here,
GetInformation event flow-diagram
Here is the event flow diagram to show the details of how this works:
iOS/Swift
For Swift, the following snippet can be sued to trigger the event, where the response can be processed in the completion handler:
Triggering GetInformation Event (Swift)
func triggerGetInformationEvent( completion: ((KsEvent?) -> Void)? = nil){
masterControllerAdapter.sendEvent2MasterController(
KSMGetInformationEvent())
{(event) in // Handle this result according to your requirement
completion?(event)}
}
Android/Kotlin
For Kotlin, we have created dedicated method in the MCHandler class of our example app to trigger respective event. Below is the code snippet:
Triggering GetInformation Event (Kotlin)
fun triggerGetInformationEvent() {
logDebug("triggering GetInformation Event", "triggerGetInformationEvent", TAG)
postEvent(GetInformationEvent())?.then {
logDebug("received Info: $it", "triggerGetInformationEvent", TAG)
// handle result
}
}