Class MailDestinationHandler
java.lang.Object
es.kukenan.smartfi.microservice.communication.service.channel.MailDestinationHandler
- All Implemented Interfaces:
NotificationChannelDestinationHandler
@Component
public class MailDestinationHandler
extends Object
implements NotificationChannelDestinationHandler
Mail destinations handler, used to extract email from several entities.
-
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
-
MailDestinationHandler
public MailDestinationHandler()
-
-
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.
-