Package-level declarations
Types
Link copied to clipboard
open class CompatibilityStreamNotificationHandler constructor(application: Application, notificationPermissionHandler: NotificationPermissionHandler = DefaultNotificationPermissionHandler.createDefaultNotificationPermissionHandler(
application,
), notificationManager: NotificationManagerCompat = NotificationManagerCompat.from(
application.applicationContext,
), intentResolver: StreamIntentResolver = DefaultStreamIntentResolver(application, DefaultNotificationIntentBundleResolver()), hideRingingNotificationInForeground: Boolean = (StreamVideo.instanceOrNull() as? StreamVideoClient)?.streamNotificationManager?.notificationConfig?.hideRingingNotificationInForeground == true, initialNotificationBuilderInterceptor: StreamNotificationBuilderInterceptors = StreamNotificationBuilderInterceptors(), updateNotificationBuilderInterceptor: StreamNotificationUpdateInterceptors = StreamNotificationUpdateInterceptors(), mediaSessionController: StreamMediaSessionController = DefaultStreamMediaSessionController(
initialNotificationBuilderInterceptor,
updateNotificationBuilderInterceptor,
), mediaSessionCallback: MediaSessionCompat.Callback? = null, notificationChannels: StreamNotificationChannels = StreamNotificationChannels(
incomingCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_incoming_call_notification_channel_id,
R.string.stream_video_incoming_call_notification_channel_title,
R.string.stream_video_incoming_call_notification_channel_description,
NotificationManager.IMPORTANCE_HIGH,
),
ongoingCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_ongoing_call_notification_channel_id,
R.string.stream_video_ongoing_call_notification_channel_title,
R.string.stream_video_ongoing_call_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
outgoingCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_outgoing_call_notification_channel_id,
R.string.stream_video_outgoing_call_notification_channel_title,
R.string.stream_video_outgoing_call_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
missedCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_missed_call_notification_channel_id,
R.string.stream_video_missed_call_notification_channel_title,
R.string.stream_video_missed_call_notification_channel_description,
NotificationManager.IMPORTANCE_HIGH,
),
missedCallLowImportanceChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_missed_call_low_priority_notification_channel_id,
R.string.stream_video_missed_call_notification_channel_title,
R.string.stream_video_missed_call_low_priority_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
incomingCallLowImportanceChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_incoming_call_low_priority_notification_channel_id,
R.string.stream_video_incoming_call_notification_channel_title,
R.string.stream_video_incoming_call_low_priority_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
)) : StreamDefaultNotificationHandler, NotificationHandler
This class is for compatibility with the old notification handler.
Link copied to clipboard
open class DefaultStreamMediaSessionController(interceptors: StreamNotificationBuilderInterceptors, updateInterceptors: StreamNotificationUpdateInterceptors) : StreamMediaSessionController
Default implementation of the StreamMediaSessionController interface.
Link copied to clipboard
open class StreamDefaultNotificationHandler constructor(application: Application, notificationManager: NotificationManagerCompat = NotificationManagerCompat.from(
application.applicationContext,
), notificationPermissionHandler: NotificationPermissionHandler = DefaultNotificationPermissionHandler.createDefaultNotificationPermissionHandler(
application,
), intentResolver: StreamIntentResolver = DefaultStreamIntentResolver(application, DefaultNotificationIntentBundleResolver()), hideRingingNotificationInForeground: Boolean = (StreamVideo.instanceOrNull() as? StreamVideoClient)?.streamNotificationManager?.notificationConfig?.hideRingingNotificationInForeground == true, initialNotificationBuilderInterceptor: StreamNotificationBuilderInterceptors = StreamNotificationBuilderInterceptors(), updateNotificationBuilderInterceptor: StreamNotificationUpdateInterceptors = StreamNotificationUpdateInterceptors(), notificationChannels: StreamNotificationChannels = StreamNotificationChannels(
incomingCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_incoming_call_notification_channel_id,
R.string.stream_video_incoming_call_notification_channel_title,
R.string.stream_video_incoming_call_notification_channel_description,
NotificationManager.IMPORTANCE_HIGH,
),
ongoingCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_ongoing_call_notification_channel_id,
R.string.stream_video_ongoing_call_notification_channel_title,
R.string.stream_video_ongoing_call_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
outgoingCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_outgoing_call_notification_channel_id,
R.string.stream_video_outgoing_call_notification_channel_title,
R.string.stream_video_outgoing_call_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
missedCallChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_missed_call_notification_channel_id,
R.string.stream_video_missed_call_notification_channel_title,
R.string.stream_video_missed_call_notification_channel_description,
NotificationManager.IMPORTANCE_HIGH,
),
missedCallLowImportanceChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_missed_call_low_priority_notification_channel_id,
R.string.stream_video_missed_call_notification_channel_title,
R.string.stream_video_missed_call_low_priority_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
incomingCallLowImportanceChannel = createChannelInfoFromResIds(
application.applicationContext,
R.string.stream_video_incoming_call_low_priority_notification_channel_id,
R.string.stream_video_incoming_call_notification_channel_title,
R.string.stream_video_incoming_call_low_priority_notification_channel_description,
NotificationManager.IMPORTANCE_DEFAULT,
),
), mediaSessionCallback: MediaSessionCompat.Callback? = null, mediaSessionController: StreamMediaSessionController = DefaultStreamMediaSessionController(
initialNotificationBuilderInterceptor,
updateNotificationBuilderInterceptor,
), notificationDispatcher: NotificationDispatcher = DefaultNotificationDispatcher(notificationManager), permissionChecker: (context: Context, permission: String) -> Int = { context, permission ->
ActivityCompat.checkSelfPermission(context, permission)
}) : StreamNotificationHandler, StreamNotificationProvider, StreamNotificationUpdatesProvider, NotificationPermissionHandler
Default implementation of the StreamNotificationHandler interface.
Link copied to clipboard
interface StreamMediaSessionController
Controller for managing media sessions.
Link copied to clipboard
Interceptor for notification builders.
Link copied to clipboard
Link copied to clipboard
data class StreamNotificationChannelInfo(val id: String, val name: String, val description: String, val importance: Int = NotificationManager.IMPORTANCE_HIGH)
Provides the channel information for the notification.
Link copied to clipboard
data class StreamNotificationChannels(val incomingCallChannel: StreamNotificationChannelInfo, val ongoingCallChannel: StreamNotificationChannelInfo, val outgoingCallChannel: StreamNotificationChannelInfo, val missedCallChannel: StreamNotificationChannelInfo, val missedCallLowImportanceChannel: StreamNotificationChannelInfo, val incomingCallLowImportanceChannel: StreamNotificationChannelInfo)
Provides the channel information for the notification.
Link copied to clipboard
Link copied to clipboard
interface StreamNotificationHandlerWithPayload
Link copied to clipboard
Link copied to clipboard
interface StreamNotificationProviderWithPayload
Link copied to clipboard
Interceptor for notification updates.
Link copied to clipboard
interface StreamNotificationUpdatesProvider