Interface DelayedNotification
-
- All Known Implementing Classes:
DelayedNotificationManager
public interface DelayedNotification
A notification that isn't sent immediately. It will be sent lately according to some of the user's preferences related to the user notification.- Author:
- Yohann Chastagnier
-
-
Method Summary
-
-
-
Method Detail
-
findAllUsersToBeNotified
List<Integer> findAllUsersToBeNotified(Set<NotifChannel> aimedChannels)
-
findUsersToBeNotified
List<Integer> findUsersToBeNotified(Date date, Set<NotifChannel> aimedChannels, DelayedNotificationFrequency defaultDelayedNotificationFrequency)
-
findDelayedNotificationByUserIdGroupByChannel
Map<NotifChannel,List<DelayedNotificationData>> findDelayedNotificationByUserIdGroupByChannel(int userId, Set<NotifChannel> aimedChannels)
-
saveDelayedNotification
void saveDelayedNotification(DelayedNotificationData delayedNotificationData)
-
deleteDelayedNotifications
int deleteDelayedNotifications(Collection<Long> ids)
-
getExistingResource
NotificationResourceData getExistingResource(String resourceId, String resourceType, String componentInstanceId)
-
getDelayedNotificationUserSetting
DelayedNotificationUserSetting getDelayedNotificationUserSetting(int id)
-
findDelayedNotificationUserSettingByUserId
List<DelayedNotificationUserSetting> findDelayedNotificationUserSettingByUserId(int userId)
-
getDelayedNotificationUserSettingByUserIdAndChannel
DelayedNotificationUserSetting getDelayedNotificationUserSettingByUserIdAndChannel(int userId, NotifChannel channel)
-
saveDelayedNotificationUserSetting
DelayedNotificationUserSetting saveDelayedNotificationUserSetting(int userId, NotifChannel channel, DelayedNotificationFrequency frequency)
-
deleteDelayedNotificationUserSetting
void deleteDelayedNotificationUserSetting(int id)
-
deleteDelayedNotificationUserSetting
void deleteDelayedNotificationUserSetting(DelayedNotificationUserSetting delayedNotificationUserSetting)
-
getWiredChannels
Set<NotifChannel> getWiredChannels()
For now, only the SMTP channel can be delayed (mail)- Returns:
-
getPossibleFrequencies
Set<DelayedNotificationFrequency> getPossibleFrequencies()
Gets the possible frequencies. At least, the default frequency.- Returns:
-
getDefaultDelayedNotificationFrequency
DelayedNotificationFrequency getDefaultDelayedNotificationFrequency()
Gets the default frequency from the file of notification manager settings. If that not exists, DelayedNotificationFrequency.NONE is returned.- Returns:
-
getUserFrequency
DelayedNotificationFrequency getUserFrequency(Integer userId, NotifChannel channel)
Gets the user notification frequency- Parameters:
userId
-- Returns:
-
-