Class CalendarEditedNotificationPlugin

java.lang.Object
org.exoplatform.container.component.BaseComponentPlugin
org.exoplatform.commons.api.notification.plugin.BaseNotificationPlugin
org.exoplatform.agenda.notification.plugin.CalendarEditedNotificationPlugin
All Implemented Interfaces:
org.exoplatform.container.component.ComponentPlugin

public class CalendarEditedNotificationPlugin extends org.exoplatform.commons.api.notification.plugin.BaseNotificationPlugin
Tells the owner of a personal calendar that a colleague they shared it with for editing wrote in it (EXO-90378), through the platform's notification framework: on site, by mail and as a push, following the owner's own notification settings like every other agenda notification.

One recipient, the owner; the sender is the colleague. The change is decided by the event service, which is the one place that knows by what right a writer wrote — this plugin only renders what it was handed, and reads nothing back: a deleted event has nothing left to read, and the three kinds of change must read alike.

Not AgendaNotificationPlugin, whose recipients are the event's attendees and whose templates speak to invitees: the owner of a shared calendar is neither.

  • Field Summary

    Fields inherited from class org.exoplatform.container.component.BaseComponentPlugin

    desc, name
  • Constructor Summary

    Constructors
    Constructor
    Description
    CalendarEditedNotificationPlugin(org.exoplatform.container.xml.InitParams initParams, org.exoplatform.social.core.manager.IdentityManager identityManager, org.exoplatform.agenda.service.AgendaCalendarService calendarService)
    Builds the plugin.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    isValid(org.exoplatform.commons.api.notification.NotificationContext ctx)
    org.exoplatform.commons.api.notification.model.NotificationInfo
    makeNotification(org.exoplatform.commons.api.notification.NotificationContext ctx)

    Methods inherited from class org.exoplatform.commons.api.notification.plugin.BaseNotificationPlugin

    buildNotification, end, getKey, getOrganizationService, getPluginConfigs, isOldPlugin, setOldPlugin, start

    Methods inherited from class org.exoplatform.container.component.BaseComponentPlugin

    getDescription, getName, setDescription, setName

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • CalendarEditedNotificationPlugin

      public CalendarEditedNotificationPlugin(org.exoplatform.container.xml.InitParams initParams, org.exoplatform.social.core.manager.IdentityManager identityManager, org.exoplatform.agenda.service.AgendaCalendarService calendarService)
      Builds the plugin.
      Parameters:
      initParams - the Kernel parameters, carrying the plugin key
      identityManager - resolves the owner and the colleague
      calendarService - names the calendar
  • Method Details

    • getId

      public String getId()
      Specified by:
      getId in class org.exoplatform.commons.api.notification.plugin.BaseNotificationPlugin
    • isValid

      public boolean isValid(org.exoplatform.commons.api.notification.NotificationContext ctx)
      Specified by:
      isValid in class org.exoplatform.commons.api.notification.plugin.BaseNotificationPlugin
    • makeNotification

      public org.exoplatform.commons.api.notification.model.NotificationInfo makeNotification(org.exoplatform.commons.api.notification.NotificationContext ctx)
      Specified by:
      makeNotification in class org.exoplatform.commons.api.notification.plugin.BaseNotificationPlugin