public class HandleNotification
extends java.lang.Object
Constructor and Description |
---|
HandleNotification() |
Modifier and Type | Method and Description |
---|---|
void |
errorHandling(PostMessage pm)
Error handling if push-receipts throws error
DeviceNotRegistered, MessageTooBig, MessageRateExceeded, InvalidCredentials
|
void |
handleNotification(java.lang.String notificationType,
java.lang.String notificationTitle,
java.lang.String bodyMessage)
Fetching all expoTokens who wants notification on one specific event
Sending push-notification to users, with title, and body message.
|
void |
sendNewADNotification(java.lang.String notificationType,
java.lang.String notificationTitle,
java.lang.String bodyMessage)
This method sends push notifications, for new ads on marketplace
|
void |
sendPushNotification(java.lang.String notificationType,
java.lang.String notificationTitle,
java.lang.String bodyMessage,
java.lang.String organisation_id,
java.lang.String associationType)
Method for sending push-notifications,
checks if number of user to receive tokens exceeds Expo's max number for sending tokens
|
public void sendPushNotification(java.lang.String notificationType, java.lang.String notificationTitle, java.lang.String bodyMessage, java.lang.String organisation_id, java.lang.String associationType)
notificationType
- StringnotificationTitle
- StringbodyMessage
- Stringorganisation_id
- StringassociationType
- Stringpublic void sendNewADNotification(java.lang.String notificationType, java.lang.String notificationTitle, java.lang.String bodyMessage)
notificationType
- StringnotificationTitle
- StringbodyMessage
- Stringpublic void handleNotification(java.lang.String notificationType, java.lang.String notificationTitle, java.lang.String bodyMessage)
notificationType
- StringnotificationTitle
- StringbodyMessage
- Stringpublic void errorHandling(PostMessage pm)
pm
- PostMessage