DefaultNotificationHandler

open class DefaultNotificationHandler(    application: Application,     notificationPermissionHandler: NotificationPermissionHandler = DefaultNotificationPermissionHandler .createDefaultNotificationPermissionHandler(application),     val hideRingingNotificationInForeground: Boolean = false,     @DrawableRes val notificationIconRes: Int = android.R.drawable.ic_menu_call) : NotificationHandler, NotificationPermissionHandler

Constructors

Link copied to clipboard
constructor(    application: Application,     notificationPermissionHandler: NotificationPermissionHandler = DefaultNotificationPermissionHandler .createDefaultNotificationPermissionHandler(application),     hideRingingNotificationInForeground: Boolean = false,     @DrawableRes notificationIconRes: Int = android.R.drawable.ic_menu_call)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

Set this to true if you want to make the ringing notifications as low-priority in case the application is in foreground. This will prevent the notification from interrupting the user while he is in the app. In this case you need to make sure to handle this call state and display an incoming call screen.

Link copied to clipboard

The notification icon for call notifications.

Functions

Link copied to clipboard
open fun NotificationCompat.Builder.addCallActions(    acceptCallPendingIntent: PendingIntent,     rejectCallPendingIntent: PendingIntent,     callDisplayName: String?): NotificationCompat.Builder
Link copied to clipboard
open fun NotificationCompat.Builder.addHangUpAction(    hangUpIntent: PendingIntent,     callDisplayName: String,     remoteParticipantCount: Int): NotificationCompat.Builder
Link copied to clipboard
open fun createIncomingCallChannel(channelId: String, showAsHighPriority: Boolean)
Link copied to clipboard
open fun createOnGoingChannel(ongoingCallsChannelId: String)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun getChannelId(): String
Link copied to clipboard
Link copied to clipboard
open override fun getIncomingCallNotification(    fullScreenPendingIntent: PendingIntent,     acceptCallPendingIntent: PendingIntent,     rejectCallPendingIntent: PendingIntent,     callerName: String?,     shouldHaveContentIntent: Boolean): Notification

Customize the notification when you receive a push notification for ringing call with type RingingState.Incoming

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun getNotificationUpdates(coroutineScope: CoroutineScope, call: Call, localUser: User, onUpdate: (Notification) -> Unit)

Get subsequent updates to notifications. Initially, notifications are posted by one of the other methods, and then this method can be used to re-post them with updated content.

Link copied to clipboard
open override fun getOngoingCallNotification(    callId: StreamCallId,     callDisplayName: String?,     isOutgoingCall: Boolean,     remoteParticipantCount: Int): Notification?

Customize the notification when you receive a push notification for ringing call with type RingingState.Outgoing and RingingState.Active

Link copied to clipboard
Link copied to clipboard
open override fun getRingingCallNotification(    ringingState: RingingState,     callId: StreamCallId,     callDisplayName: String?,     shouldHaveContentIntent: Boolean): Notification?

Customize the notification when you receive a push notification for ringing call

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun maybeCreateChannel(channelId: String, context: Context, configure: NotificationChannel.() -> Unit = { })
Link copied to clipboard
open override fun onLiveCall(callId: StreamCallId, callDisplayName: String)

Customize the notification when you receive a push notification for Live Call

Link copied to clipboard
open override fun onMissedCall(callId: StreamCallId, callDisplayName: String)

Customize the notification when you receive a push notification for Missed Call

Link copied to clipboard
open override fun onNotification(callId: StreamCallId, callDisplayName: String)

Customize the notification when you receive a push notification for general usage

Link copied to clipboard
open override fun onRingingCall(callId: StreamCallId, callDisplayName: String)

Customize the notification when you receive a push notification for ringing call, which has further two types RingingState.Incoming and RingingState.Outgoing

Link copied to clipboard
open fun showLiveCallNotification(liveCallPendingIntent: PendingIntent, callDisplayName: String, notificationId: Int)
Link copied to clipboard
open fun showMissedCallNotification(notificationPendingIntent: PendingIntent, callDisplayName: String, notificationId: Int)
Link copied to clipboard
open fun showNotificationCallNotification(notificationPendingIntent: PendingIntent, callDisplayName: String, notificationId: Int)

Inherited functions

Link copied to clipboard
open override fun onPermissionDenied()
Link copied to clipboard
open override fun onPermissionGranted()
Link copied to clipboard
open override fun onPermissionRationale()
Link copied to clipboard
open override fun onPermissionRequested()