Package com.zendesk.connect
Class ConnectMessagingService
- java.lang.Object
-
- FirebaseMessagingService
-
- com.zendesk.connect.ConnectMessagingService
-
public class ConnectMessagingService extends FirebaseMessagingService
Service class to receive push notifications from Firebase. Connect will attempt to handle the push payload and invoke:MessageReceiver
to control non-Connect messages, and pass along other Firebase eventsNotificationEventListener
to react to notification eventsNotificationFactory
to create custom display notifications.
-
-
Constructor Summary
Constructors Constructor and Description ConnectMessagingService()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description void
onDeletedMessages()
void
onMessageReceived(RemoteMessage message)
void
onMessageSent(java.lang.String s)
void
onNewToken(java.lang.String s)
void
onSendError(java.lang.String s, java.lang.Exception e)
static void
setMessageReceiver(MessageReceiver messageReceiver)
Sets an implementation ofMessageReceiver
to be invoked when a non-ConnectRemoteMessage
is received.static void
setNotificationEventListener(NotificationEventListener notificationEventListener)
Sets an implementation ofNotificationEventListener
to be invoked when notification events occurstatic void
setNotificationFactory(NotificationFactory notificationFactory)
Sets an implementation ofNotificationFactory
to be invoked when a display notification is being created.
-
-
-
Method Detail
-
onMessageReceived
public final void onMessageReceived(RemoteMessage message)
-
onDeletedMessages
public final void onDeletedMessages()
-
onMessageSent
public final void onMessageSent(java.lang.String s)
-
onSendError
public final void onSendError(java.lang.String s, java.lang.Exception e)
-
onNewToken
public final void onNewToken(java.lang.String s)
-
setMessageReceiver
public static void setMessageReceiver(MessageReceiver messageReceiver)
Sets an implementation ofMessageReceiver
to be invoked when a non-ConnectRemoteMessage
is received.- Parameters:
messageReceiver
- an implementation ofMessageReceiver
-
setNotificationEventListener
public static void setNotificationEventListener(NotificationEventListener notificationEventListener)
Sets an implementation ofNotificationEventListener
to be invoked when notification events occur- Parameters:
notificationEventListener
- an implementation ofNotificationEventListener
-
setNotificationFactory
public static void setNotificationFactory(NotificationFactory notificationFactory)
Sets an implementation ofNotificationFactory
to be invoked when a display notification is being created.- Parameters:
notificationFactory
- an implementation ofNotificationFactory
-
-