Open Journal Systems  3.3.0
AnnouncementNotificationManager Class Reference
Inheritance diagram for AnnouncementNotificationManager:
NotificationManagerDelegate PKPNotificationOperationManager INotificationInfoProvider

Public Member Functions

 getIconClass ($notification)
 
 getNotificationContents ($request, $notification)
 
 getNotificationMessage ($request, $notification)
 
 getNotificationUrl ($request, $notification)
 
 getStyleClass ($notification)
 
 initialize (Announcement $announcement)
 
 notify (User $user)
 
- Public Member Functions inherited from NotificationManagerDelegate
 __construct ($notificationType)
 
 createNotification ($request, $userId=null, $notificationType, $contextId=null, $assocType=null, $assocId=null, $level=NOTIFICATION_LEVEL_NORMAL, $params=null, $suppressEmail=false, callable $mailConfigurator=null)
 
 getNotificationType ()
 
 updateNotification ($request, $userIds, $assocType, $assocId)
 
- Public Member Functions inherited from PKPNotificationOperationManager
 createTrivialNotification ($userId, $notificationType=NOTIFICATION_TYPE_SUCCESS, $params=null)
 
 deleteTrivialNotifications ($notifications)
 
 formatToGeneralNotification ($request, $notifications)
 
 formatToInPlaceNotification ($request, $notifications)
 
 getFormattedNotificationsForUser ($request, $userId, $level=NOTIFICATION_LEVEL_NORMAL, $contextId=null, $rangeInfo=null, $notificationTemplate='notification/notification.tpl')
 
 getNotificationTitle ($notification)
 
 getParamsForCurrentLocale ($params)
 
 isVisibleToAllUsers ($notificationType, $assocType, $assocId)
 

Data Fields

 $_announcement
 

Protected Member Functions

 getMailTemplate ($emailKey=null)
 
- Protected Member Functions inherited from NotificationManagerDelegate
 multipleTypesUpdate ()
 
- Protected Member Functions inherited from PKPNotificationOperationManager
 fetchLinkActionNotificationContent ($linkAction, $request)
 
 getUserBlockedEmailedNotifications ($userId, $contextId)
 
 getUserBlockedNotifications ($userId, $contextId)
 
 sendNotificationEmail ($request, $notification, ?int $contextId, callable $mailConfigurator=null)
 

Detailed Description

New announcement notification manager.

Definition at line 17 of file AnnouncementNotificationManager.inc.php.

Member Function Documentation

◆ getIconClass()

AnnouncementNotificationManager::getIconClass (   $notification)

Provide the notification message as default content. Get the notification contents. Content is anything that's more than text, like presenting link actions inside fetched template files.

Parameters
$requestPKPRequest
$notificationNotification
Returns
string

Reimplemented from PKPNotificationOperationManager.

Definition at line 63 of file AnnouncementNotificationManager.inc.php.

◆ getMailTemplate()

AnnouncementNotificationManager::getMailTemplate (   $emailKey = null)
protected

Get a template mail instance.

Parameters
$emailKeystring
Returns
MailTemplate
See also
MailTemplate

Reimplemented from PKPNotificationOperationManager.

Definition at line 99 of file AnnouncementNotificationManager.inc.php.

References PKPServices\get(), and PKPApplication\get().

◆ getNotificationContents()

AnnouncementNotificationManager::getNotificationContents (   $request,
  $notification 
)

Get the notification message. Only return translated locale key strings.

Parameters
$requestPKPRequest
$notificationNotification
Returns
string

Reimplemented from PKPNotificationOperationManager.

Definition at line 42 of file AnnouncementNotificationManager.inc.php.

References PKPServices\get().

◆ getNotificationMessage()

AnnouncementNotificationManager::getNotificationMessage (   $request,
  $notification 
)

Get the notification message. Only return translated locale key strings.

Parameters
$requestPKPRequest
$notificationNotification
Returns
string

Reimplemented from PKPNotificationOperationManager.

Definition at line 35 of file AnnouncementNotificationManager.inc.php.

◆ getNotificationUrl()

AnnouncementNotificationManager::getNotificationUrl (   $request,
  $notification 
)

Get a URL for the notification.

Parameters
$requestPKPRequest
$notificationNotification
Returns
string

Reimplemented from PKPNotificationOperationManager.

Definition at line 49 of file AnnouncementNotificationManager.inc.php.

◆ getStyleClass()

AnnouncementNotificationManager::getStyleClass (   $notification)

Provide the notification message as default content. Get the notification contents. Content is anything that's more than text, like presenting link actions inside fetched template files.

Parameters
$requestPKPRequest
$notificationNotification
Returns
string

Reimplemented from PKPNotificationOperationManager.

Definition at line 70 of file AnnouncementNotificationManager.inc.php.

◆ initialize()

AnnouncementNotificationManager::initialize ( Announcement  $announcement)

Initializes the class.

Parameters
Announcement$announcementThe announcement to send

Definition at line 28 of file AnnouncementNotificationManager.inc.php.

◆ notify()

AnnouncementNotificationManager::notify ( User  $user)

Sends a notification to the given user.

Parameters
$userUser The user who will be notified
Returns
PKPNotification|null The notification instance or null if no notification created

Definition at line 79 of file AnnouncementNotificationManager.inc.php.

References PKPApplication\get().

Field Documentation

◆ $_announcement

array AnnouncementNotificationManager::$_announcement

The announcement to send a notification about

Definition at line 22 of file AnnouncementNotificationManager.inc.php.


The documentation for this class was generated from the following file: