//sorisdk/com.iplateia.sorisdk/SORIAudioRecognizer/getServiceIntent
getServiceIntent
[androidJvm]
fun getServiceIntent(ctx: Context, title: String? = "SORI Audio Recognizer", body: String? = "Listening...", icon: Int? = android.R.drawable.ic_menu_info_details): Intent
Creates an intent to start the SORI Audio Recognition Service. This intent can be used to start the service from an activity or another component. example usage:
kotlin
val intent = SORIAudioRecognizer.getServiceIntent(this)
this.startForegroundService(intent)
Return
An intent to start the SORI Audio Recognition Service.
Parameters
androidJvm
ctx | The context from which the service is started. |
title | The title of the notification. (optional) |
body | The body of the notification. (optional) |
icon | The icon resource ID for the notification. (optional) |