Class DefaultNotificationHandler
-
- All Implemented Interfaces:
-
io.getstream.android.push.permissions.NotificationPermissionHandler,io.getstream.video.android.core.notifications.NotificationHandler
public class DefaultNotificationHandler implements NotificationHandler, NotificationPermissionHandler
-
-
Field Summary
Fields Modifier and Type Field Description private final BooleanhideRingingNotificationInForegroundprivate final IntegernotificationIconRes
-
Constructor Summary
Constructors Constructor Description DefaultNotificationHandler(Application application, NotificationPermissionHandler notificationPermissionHandler, Boolean hideRingingNotificationInForeground, Integer notificationIconRes)
-
Method Summary
Modifier and Type Method Description final BooleangetHideRingingNotificationInForeground()Set this to true if you want to make the ringing notifications as low-priority in case the application is in foreground. final IntegergetNotificationIconRes()The notification icon for call notifications. UnitonRingingCall(StreamCallId callId, String callDisplayName)NotificationgetRingingCallNotification(RingingState ringingState, StreamCallId callId, String callDisplayName, Boolean shouldHaveContentIntent)UnitonNotification(StreamCallId callId, String callDisplayName)UnitonLiveCall(StreamCallId callId, String callDisplayName)NotificationgetOngoingCallNotification(String callDisplayName, StreamCallId callId)StringgetChannelId()StringgetChannelName()StringgetChannelDescription()-
Methods inherited from class io.getstream.android.push.permissions.NotificationPermissionHandler
onPermissionDenied, onPermissionGranted, onPermissionRationale, onPermissionRequested -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
DefaultNotificationHandler
DefaultNotificationHandler(Application application, NotificationPermissionHandler notificationPermissionHandler, Boolean hideRingingNotificationInForeground, Integer notificationIconRes)
-
-
Method Detail
-
getHideRingingNotificationInForeground
final Boolean getHideRingingNotificationInForeground()
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.
-
getNotificationIconRes
final Integer getNotificationIconRes()
The notification icon for call notifications.
-
onRingingCall
Unit onRingingCall(StreamCallId callId, String callDisplayName)
-
getRingingCallNotification
Notification getRingingCallNotification(RingingState ringingState, StreamCallId callId, String callDisplayName, Boolean shouldHaveContentIntent)
-
onNotification
Unit onNotification(StreamCallId callId, String callDisplayName)
-
onLiveCall
Unit onLiveCall(StreamCallId callId, String callDisplayName)
-
getOngoingCallNotification
Notification getOngoingCallNotification(String callDisplayName, StreamCallId callId)
-
getChannelId
String getChannelId()
-
getChannelName
String getChannelName()
-
getChannelDescription
String getChannelDescription()
-
-
-
-