Class RedisSubscriptionAdapter
java.lang.Object
com.blackrook.redis.event.RedisSubscriptionAdapter
- All Implemented Interfaces:
RedisSubscriptionListener
An adapter class for
RedisSubscriptionListener. All methods do nothing on call.- Author:
- Matthew Tropiano
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidonMessageReceive(String channel, String message) Called when this subscription connection receives a message from a channel.voidonPatternMessageReceive(String channelPattern, String channel, String message) Called when this subscription connection receives a message from a channel.voidonPatternSubscribe(String channelPattern, long channelTotal) Called when this subscription connection subscribes to a set of channels via a pattern.voidonPatternUnsubscribe(String channelPattern, long channelTotal) Called when this subscription connection unsubscribes from a set of channels via a pattern.voidonSubscribe(String channelName, long channelTotal) Called when this subscription connection subscribes to a channel.voidonUnsubscribe(String channelName, long channelTotal) Called when this subscription connection unsubscribes from a channel.
-
Constructor Details
-
RedisSubscriptionAdapter
public RedisSubscriptionAdapter()
-
-
Method Details
-
onSubscribe
Description copied from interface:RedisSubscriptionListenerCalled when this subscription connection subscribes to a channel.- Specified by:
onSubscribein interfaceRedisSubscriptionListener- Parameters:
channelName- the subscribed channel.channelTotal- the total number of channels that this subscriber is subscribed to.
-
onUnsubscribe
Description copied from interface:RedisSubscriptionListenerCalled when this subscription connection unsubscribes from a channel.- Specified by:
onUnsubscribein interfaceRedisSubscriptionListener- Parameters:
channelName- the channel that this unsubscribed from.channelTotal- the total number of channels that this subscriber is subscribed to.
-
onPatternSubscribe
Description copied from interface:RedisSubscriptionListenerCalled when this subscription connection subscribes to a set of channels via a pattern.- Specified by:
onPatternSubscribein interfaceRedisSubscriptionListener- Parameters:
channelPattern- the channel pattern that this subscribed to.channelTotal- the total number of channels that this subscriber is subscribed to.
-
onPatternUnsubscribe
Description copied from interface:RedisSubscriptionListenerCalled when this subscription connection unsubscribes from a set of channels via a pattern.- Specified by:
onPatternUnsubscribein interfaceRedisSubscriptionListener- Parameters:
channelPattern- the channel pattern that this unsubscribed from.channelTotal- the total number of channels that this subscriber is subscribed to.
-
onMessageReceive
Description copied from interface:RedisSubscriptionListenerCalled when this subscription connection receives a message from a channel.- Specified by:
onMessageReceivein interfaceRedisSubscriptionListener- Parameters:
channel- the channel that the message came from.message- the message received.
-
onPatternMessageReceive
Description copied from interface:RedisSubscriptionListenerCalled when this subscription connection receives a message from a channel.- Specified by:
onPatternMessageReceivein interfaceRedisSubscriptionListener- Parameters:
channelPattern- the channel pattern that was matched.channel- the channel that the message came from.message- the message received.
-