public class SimplePushNotificationSender extends Object implements PushNotificationSender
| Constructor and Description |
|---|
SimplePushNotificationSender() |
| Modifier and Type | Method and Description |
|---|---|
protected HttpURLConnection |
getConnection(String url) |
protected HttpURLConnection |
put(String url,
String body) |
void |
sendPushMessage(Variant variant,
Collection<String> tokens,
UnifiedPushMessage pushMessage,
String pushMessageInformationId,
NotificationSenderCallback callback)
Sends the
UnifiedPushMessage to the given clients, identified by a collection of tokens, the underlying push network. |
public void sendPushMessage(Variant variant, Collection<String> tokens, UnifiedPushMessage pushMessage, String pushMessageInformationId, NotificationSenderCallback callback)
PushNotificationSenderUnifiedPushMessage to the given clients, identified by a collection of tokens, the underlying push network.sendPushMessage in interface PushNotificationSendervariant - contains details for the underlying push network, e.g. API Keys/Idstokens - platform specific collection of client identifierspushMessage - payload to be send to the given clientspushMessageInformationId - the id of the PushMessageInformation instance associated with this send.callback - invoked after submitting the request to the underlying push network to indicate the status
of the request (success or errorprotected HttpURLConnection put(String url, String body) throws IOException
IOExceptionprotected HttpURLConnection getConnection(String url) throws IOException
IOExceptionCopyright © 2015 JBoss by Red Hat. All Rights Reserved.