com.atlassian.confluence.mail.notification
Class DefaultNotificationsSender

java.lang.Object
  extended by com.atlassian.confluence.mail.notification.DefaultNotificationsSender
All Implemented Interfaces:
NotificationsSender

public class DefaultNotificationsSender
extends Object
implements NotificationsSender


Constructor Summary
DefaultNotificationsSender(UserAccessor userAccessor, com.atlassian.core.task.MultiQueueTaskManager taskManager, NotificationManager notificationManager, Renderer viewRenderer, PermissionManager permissionManager, FormatSettingsManager formatSettingsManager, com.atlassian.plugin.webresource.WebResourceManager webResourceManager, I18NBeanFactory i18NBeanFactory, LocaleManager localeManager, Differ differ, NotificationRenderManager notificationRenderManager, DataSourceFactory dataSourceFactory)
           
 
Method Summary
protected  com.atlassian.mail.queue.MailQueueItem createNotificationTask(com.atlassian.user.User toUser, NotificationData notificationData, String renderedSubject, NotificationContext context)
           
 void sendNetworkNotifications(NotificationData notificationData, ConversionContext conversionContext)
          Sends notifications based on users following other users.
 void sendNotification(ConfluenceUser toUser, NotificationContext context, NotificationData notificationData, ConversionContext conversionContext)
           
 void sendNotification(Notification notification, NotificationData notificationData, ConversionContext conversionContext)
          Sends content-based notifications.
 void sendNotification(String recipient, NotificationContext context, NotificationData notificationData, ConversionContext conversionContext)
          Sends a notification.
 void sendNotifications(List<Notification> notifications, NotificationData notificationData, ConversionContext conversionContext)
          Sends the notificationData to each user listed in notifications, as long as they are permitted to see it.
 void sendPageNotifications(AbstractPage page, NotificationData notificationData, ConversionContext conversionContext)
          Sends page based notifications.
 void sendSpaceNotifications(Space space, NotificationData notificationData, ConversionContext conversionContext)
          Sends space based notifications.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultNotificationsSender

public DefaultNotificationsSender(UserAccessor userAccessor,
                                  com.atlassian.core.task.MultiQueueTaskManager taskManager,
                                  NotificationManager notificationManager,
                                  Renderer viewRenderer,
                                  PermissionManager permissionManager,
                                  FormatSettingsManager formatSettingsManager,
                                  com.atlassian.plugin.webresource.WebResourceManager webResourceManager,
                                  I18NBeanFactory i18NBeanFactory,
                                  LocaleManager localeManager,
                                  Differ differ,
                                  NotificationRenderManager notificationRenderManager,
                                  DataSourceFactory dataSourceFactory)
Method Detail

sendNotification

public final void sendNotification(Notification notification,
                                   NotificationData notificationData,
                                   ConversionContext conversionContext)
Description copied from interface: NotificationsSender
Sends content-based notifications. Generates link to stop watching a notification and adds a link to manage content notification settings

Specified by:
sendNotification in interface NotificationsSender
Parameters:
notification - the watch that triggered the notification being sent
notificationData - data for rendering the email
conversionContext - conversionContext specific to the type of entity the email is being sent about

sendNotification

public final void sendNotification(String recipient,
                                   NotificationContext context,
                                   NotificationData notificationData,
                                   ConversionContext conversionContext)
Sends a notification. Checks the permissions before sending.

Specified by:
sendNotification in interface NotificationsSender

sendNotification

public final void sendNotification(ConfluenceUser toUser,
                                   NotificationContext context,
                                   NotificationData notificationData,
                                   ConversionContext conversionContext)

sendPageNotifications

public void sendPageNotifications(AbstractPage page,
                                  NotificationData notificationData,
                                  ConversionContext conversionContext)
Description copied from interface: NotificationsSender
Sends page based notifications.

Specified by:
sendPageNotifications in interface NotificationsSender
Parameters:
page - the page related to the notifications to be sent.
notificationData - data for rendering the email
conversionContext - conversionContext specific to the type of entity the email is being sent about

sendSpaceNotifications

public void sendSpaceNotifications(Space space,
                                   NotificationData notificationData,
                                   ConversionContext conversionContext)
Description copied from interface: NotificationsSender
Sends space based notifications.

Specified by:
sendSpaceNotifications in interface NotificationsSender
Parameters:
space - the space related to the notifications to be sent.

sendNetworkNotifications

public void sendNetworkNotifications(NotificationData notificationData,
                                     ConversionContext conversionContext)
Description copied from interface: NotificationsSender
Sends notifications based on users following other users.

Specified by:
sendNetworkNotifications in interface NotificationsSender

sendNotifications

public void sendNotifications(List<Notification> notifications,
                              NotificationData notificationData,
                              ConversionContext conversionContext)
Description copied from interface: NotificationsSender
Sends the notificationData to each user listed in notifications, as long as they are permitted to see it.

Specified by:
sendNotifications in interface NotificationsSender

createNotificationTask

protected com.atlassian.mail.queue.MailQueueItem createNotificationTask(com.atlassian.user.User toUser,
                                                                        NotificationData notificationData,
                                                                        String renderedSubject,
                                                                        NotificationContext context)


Copyright © 2003–2015 Atlassian. All rights reserved.