Class NotificationConfig
-
- All Implemented Interfaces:
public final class NotificationConfigPush notifications configuration class
-
-
Field Summary
Fields Modifier and Type Field Description private final BooleanpushNotificationsEnabledprivate final BooleanignorePushMessagesWhenUserOnlineprivate final List<PushDeviceGenerator>pushDeviceGeneratorsprivate final Function0<Boolean>shouldShowNotificationOnPushprivate final Function0<Boolean>requestPermissionOnAppLaunch
-
Constructor Summary
Constructors Constructor Description NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline, List<PushDeviceGenerator> pushDeviceGenerators, Function0<Boolean> shouldShowNotificationOnPush, Function0<Boolean> requestPermissionOnAppLaunch)NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline, List<PushDeviceGenerator> pushDeviceGenerators, Function0<Boolean> shouldShowNotificationOnPush)NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline, List<PushDeviceGenerator> pushDeviceGenerators)NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline)NotificationConfig(Boolean pushNotificationsEnabled)NotificationConfig()
-
Method Summary
Modifier and Type Method Description final BooleangetPushNotificationsEnabled()Enables/disables push notifications on the device. final BooleangetIgnorePushMessagesWhenUserOnline()Push notifications are ignored and not displayed when the user is online (when there is an active WebSocket connection). final List<PushDeviceGenerator>getPushDeviceGenerators()A list of generators responsible for providing the information needed to register a device final Function0<Boolean>getShouldShowNotificationOnPush()Allows enabling/disabling showing notification after receiving a push message. final Function0<Boolean>getRequestPermissionOnAppLaunch()Allows SDK to request android.Manifest.permission.POST_NOTIFICATIONS permission for a connected user. -
-
Constructor Detail
-
NotificationConfig
NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline, List<PushDeviceGenerator> pushDeviceGenerators, Function0<Boolean> shouldShowNotificationOnPush, Function0<Boolean> requestPermissionOnAppLaunch)
-
NotificationConfig
NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline, List<PushDeviceGenerator> pushDeviceGenerators, Function0<Boolean> shouldShowNotificationOnPush)
-
NotificationConfig
NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline, List<PushDeviceGenerator> pushDeviceGenerators)
-
NotificationConfig
NotificationConfig(Boolean pushNotificationsEnabled, Boolean ignorePushMessagesWhenUserOnline)
-
NotificationConfig
NotificationConfig(Boolean pushNotificationsEnabled)
-
NotificationConfig
NotificationConfig()
-
-
Method Detail
-
getPushNotificationsEnabled
final Boolean getPushNotificationsEnabled()
Enables/disables push notifications on the device. Device's token won't be registered if push notifications are disabled.
-
getIgnorePushMessagesWhenUserOnline
final Boolean getIgnorePushMessagesWhenUserOnline()
Push notifications are ignored and not displayed when the user is online (when there is an active WebSocket connection). Set to false if you would like to receive and handle push notifications even if user is online. Default value is true.
-
getPushDeviceGenerators
final List<PushDeviceGenerator> getPushDeviceGenerators()
A list of generators responsible for providing the information needed to register a device
-
getShouldShowNotificationOnPush
final Function0<Boolean> getShouldShowNotificationOnPush()
Allows enabling/disabling showing notification after receiving a push message.
-
getRequestPermissionOnAppLaunch
final Function0<Boolean> getRequestPermissionOnAppLaunch()
Allows SDK to request android.Manifest.permission.POST_NOTIFICATIONS permission for a connected user.
-
-
-
-