Aller au contenu principal
Version: Next

SPNotification

com.surpuissant.kws.sdk

SPNotification Class

The SPNotification class is used to create notifications in Surpuissant's SDK. It contains two properties, title, and content, which are used to set the title and content of a notification respectively. The icon property is optional and can be used to specify an icon for the notification.

Properties

PropertyTypeDescriptionDefault Value
titleStringThe title of the notification."SDK Surpuissant"
contentStringThe content of the notification."Assistance vocale activée"
iconIntAn optional icon for the notification.0x7f0600a8 (R.drawable.logo_surpuissant)

Methods

extractFromIntent(intent: Intent?)

Extracts a SPNotification object from an intent. The extracted notification will have the title, content, and icon set to the values provided in the intent's extras. If no title or content is found in the intent, it defaults to "SDK Surpuissant" for the title and "Assistance vocale activée" for the content.