Beacon Push Notifications Processor
Processes push notifications from Firebase Cloud Messaging (FCM) for the Beacon SDK.
This processor is used when your application already handles FCM push messaging. It allows you to identify and process Beacon-specific notifications within your existing FCM infrastructure.
Usage:
- In your
FirebaseMessagingService.onMessageReceived(), check if the message is for Beacon using isBeaconNotification - If it is a Beacon notification, call process to display the notification
Example:
@Override
public void onMessageReceived(RemoteMessage remoteMessage) {
if (remoteMessage.getData().size() > 0) {
BeaconPushNotificationsProcessor processor = new BeaconPushNotificationsProcessor();
if (BeaconPushNotificationsProcessor.isBeaconNotification(remoteMessage.getData())) {
processor.process(this, remoteMessage.getData());
} else {
// Handle your own push messages
}
}
}Content copied to clipboard