createNotificationChannel

Helps to create the Voxeet default channel. It is used because Firebase and Android require applications to have their own valid notification channels.

Return

a flag indicating if the channel is set properly. A false value informs that this method was already called for the Android version where it's mandatory. Android versions prior to Android O always return a true value.

Parameters

context

that will be manipulated to create the channel


open fun createNotificationChannel(@NonNull context: Context, @NonNull id: String, @NonNull name: CharSequence, @NonNull description: String, argb: Int): Boolean

Creates the notification channel because Firebase and Android require applications to have their own valid notification channels.

Return

a flag indicating if the channel is set up properly. A false value informs that this method was already called for the Android version where it is mandatory. Android versions prior to Android O always return a true value.

Parameters

context

that will be manipulated to create the channel

id

channel ID

name

displayed name of the channel (to be translated)

description

description of the channel (to be translated)

argb

color of the notifications in the 0xaarrggbb representation