Package pl.edu.icm.unity.engine.api
Interface NotificationsManagement
public interface NotificationsManagement
Management and usage of notifications subsystem (email, sms, ...)
- Author:
- K. Benedyczak
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addNotificationChannel
(pl.edu.icm.unity.base.notifications.NotificationChannel toAdd) Creates a new channel for a given facility.getNotificationChannelsForTechnologies
(EnumSet<pl.edu.icm.unity.base.notifications.CommunicationTechnology> facilites) void
removeNotificationChannel
(String channelName) Removes a specified channel.void
updateNotificationChannel
(String channelName, String newConfiguration) Changes configuration of an existing notification channel.
-
Method Details
-
getNotificationFacilities
- Returns:
- set with names of all available notification facilities (implementations). E.g. email sender can be a facility.
- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
addNotificationChannel
void addNotificationChannel(pl.edu.icm.unity.base.notifications.NotificationChannel toAdd) throws pl.edu.icm.unity.base.exceptions.EngineException Creates a new channel for a given facility. E.g. a new email facility configured to use a concrete SMTP server.- Parameters:
toAdd
-- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
removeNotificationChannel
void removeNotificationChannel(String channelName) throws pl.edu.icm.unity.base.exceptions.EngineException Removes a specified channel.- Parameters:
channelName
-- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
updateNotificationChannel
void updateNotificationChannel(String channelName, String newConfiguration) throws pl.edu.icm.unity.base.exceptions.EngineException Changes configuration of an existing notification channel.- Parameters:
channelName
-newConfiguration
-- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getNotificationChannels
Map<String,pl.edu.icm.unity.base.notifications.NotificationChannelInfo> getNotificationChannels() throws pl.edu.icm.unity.base.exceptions.EngineException- Returns:
- map of available notification channels.
- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-
getNotificationChannelsForTechnologies
Map<String,pl.edu.icm.unity.base.notifications.NotificationChannelInfo> getNotificationChannelsForTechnologies(EnumSet<pl.edu.icm.unity.base.notifications.CommunicationTechnology> facilites) throws pl.edu.icm.unity.base.exceptions.EngineException - Returns:
- get available notification channels which are using given communication technologies.
- Throws:
pl.edu.icm.unity.base.exceptions.EngineException
-