public class DefaultNotificationTransport extends AbstractKaaTransport implements NotificationTransport
channelManager, clientState
Constructor and Description |
---|
DefaultNotificationTransport() |
Modifier and Type | Method and Description |
---|---|
org.kaaproject.kaa.common.endpoint.gen.NotificationSyncRequest |
createEmptyNotificationRequest()
Creates a new empty Notification request.
|
org.kaaproject.kaa.common.endpoint.gen.NotificationSyncRequest |
createNotificationRequest()
Creates a new Notification request.
|
protected org.kaaproject.kaa.common.TransportType |
getTransportType() |
void |
onNotificationResponse(org.kaaproject.kaa.common.endpoint.gen.NotificationSyncResponse response)
Updates the state of the Notification manager according to the given response.
|
void |
onSubscriptionChanged(List<org.kaaproject.kaa.common.endpoint.gen.SubscriptionCommand> commands)
Notify about new subscription info.
|
void |
setNotificationProcessor(NotificationProcessor processor)
Sets the given Notification processor.
|
setChannelManager, setClientState, sync, syncAck, syncAck, syncAckByType, syncAll, syncByType, syncByType
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
setChannelManager, setClientState, sync
public org.kaaproject.kaa.common.endpoint.gen.NotificationSyncRequest createEmptyNotificationRequest()
NotificationTransport
createEmptyNotificationRequest
in interface NotificationTransport
NotificationSyncRequest
public org.kaaproject.kaa.common.endpoint.gen.NotificationSyncRequest createNotificationRequest()
NotificationTransport
createNotificationRequest
in interface NotificationTransport
NotificationSyncRequest
public void onNotificationResponse(org.kaaproject.kaa.common.endpoint.gen.NotificationSyncResponse response) throws IOException
NotificationTransport
onNotificationResponse
in interface NotificationTransport
response
- the response from the server.IOException
NotificationSyncResponse
public void onSubscriptionChanged(List<org.kaaproject.kaa.common.endpoint.gen.SubscriptionCommand> commands)
NotificationTransport
Notify about new subscription info.
Will be called when one either subscribes or unsubscribes on\from some optional topic(s).
onSubscriptionChanged
in interface NotificationTransport
commands
- Info about subscription actions (subscribe/unsubscribe).public void setNotificationProcessor(NotificationProcessor processor)
NotificationTransport
setNotificationProcessor
in interface NotificationTransport
processor
- the Notification processor which to be set.NotificationProcessor
protected org.kaaproject.kaa.common.TransportType getTransportType()
getTransportType
in class AbstractKaaTransport
Copyright © 2015. All rights reserved.