com.streamhub.api
Interface SubscriptionListener

public interface SubscriptionListener

This interface is used to receive callbacks when a client
subscribes or unsubscribes from a topic.

A subscription to a topic is a request to receive streaming
data on this topic. For example a subscription to the topic
'MSFT' could represent a request to receive stock quotes on
the ticker symbol 'MSFT'.

onUnSubscribe

It is possible to return a response to the client using
Client.send(String, Payload). However, by the time this
method has been called, the client will have been removed from
StreamHubs internal subscription map so any calls to
NIOServer.publish(String, Payload) will not send data to
this client. If for some reason you wish to
still send data to this unsubscribed
client you will need to save the client parameter for later use.