public class GCMSenderRPC extends DispatchHandler implements IGCMSender
RelayType.ANDROID devices are relayed in the network. The GCM server authentication keys should not
be distributed in the whole network (because of privacy) and thus, this RPC acts as the key-holder and
server to send GCM messages. Relayed Android devices need to provide the PeerAddress of one or
multiple GCMSenders of this kind.| Constructor and Description |
|---|
GCMSenderRPC(Peer peer,
String authenticationKey,
int retries) |
| Modifier and Type | Method and Description |
|---|---|
void |
handleResponse(Message message,
PeerConnection peerConnection,
boolean sign,
Responder responder)
This method is called from the
Dispatcher and handles GCM requests
REQUEST_1 = forward the GCM request to the mobile device. |
void |
send(FutureGCM futureGCM)
Tickle the device through Google Cloud Messaging
|
connectionBean, createMessage, createResponseMessage, createResponseMessage, forwardMessage, peerBean, register, register, signpublic void handleResponse(Message message, PeerConnection peerConnection, boolean sign, Responder responder) throws Exception
Dispatcher and handles GCM requests
REQUEST_1 = forward the GCM request to the mobile device.handleResponse in class DispatchHandlermessage - peerConnection - sign - responder - Exceptionpublic void send(FutureGCM futureGCM)
IGCMSendersend in interface IGCMSenderfutureGCM - the tickle request containing also the buffered messagesCopyright © 2014. All rights reserved.