Class SmsDestinationHandler
java.lang.Object
es.kukenan.smartfi.microservice.communication.service.channel.SmsDestinationHandler
- All Implemented Interfaces:
NotificationChannelDestinationHandler
- Direct Known Subclasses:
PushDestinationHandler
@Component
public class SmsDestinationHandler
extends Object
implements NotificationChannelDestinationHandler
Notification channel destination handler manager, used to find the proper channel destination handler for a given channel.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanaccepts(NotificationChannel channel) Return true if this handler is able to send the given notification channel.getAddress(Receiver receiver) Get the destination address for this channel.getAddress(User user) Get the destination address for this channel.
-
Constructor Details
-
SmsDestinationHandler
public SmsDestinationHandler()
-
-
Method Details
-
getAddress
Description copied from interface:NotificationChannelDestinationHandlerGet the destination address for this channel.- Specified by:
getAddressin interfaceNotificationChannelDestinationHandler- Parameters:
user- the user entity.- Returns:
- the channel-specific destination.
-
getAddress
Description copied from interface:NotificationChannelDestinationHandlerGet the destination address for this channel.- Specified by:
getAddressin interfaceNotificationChannelDestinationHandler- Parameters:
receiver- receiver entity.- Returns:
- the channel-specific destination.
-
accepts
Description copied from interface:NotificationChannelDestinationHandlerReturn true if this handler is able to send the given notification channel.- Specified by:
acceptsin interfaceNotificationChannelDestinationHandler- Parameters:
channel- notification channel.- Returns:
- true if this handler is able to send the given notification channel.
-