Class AbstractNotificationPlugin

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

public abstract class AbstractNotificationPlugin extends BaseNotificationPlugin
  • Constructor Details

    • AbstractNotificationPlugin

      public AbstractNotificationPlugin(org.exoplatform.container.xml.InitParams initParams)
  • Method Details

    • makeMessage

      protected abstract MessageInfo makeMessage(NotificationContext ctx)
      Makes the MessageInfor from given NotificationMessage what keep inside NotificationContext
      Parameters:
      ctx -
      Returns:
    • makeDigest

      protected abstract boolean makeDigest(NotificationContext ctx, Writer writer)
      Makes the Digest message from given NotificationMessage what keep inside NotificationContext
      Parameters:
      ctx -
      writer -
      Returns:
    • buildMessage

      public MessageInfo buildMessage(NotificationContext ctx)
      Makes massage
      Parameters:
      ctx -
      Returns:
    • buildDigest

      public boolean buildDigest(NotificationContext ctx, Writer writer)
      Makes digest message
      Parameters:
      ctx -
      writer -
      Returns:
    • getKey

      public PluginKey getKey()
      Creates the key for NotificationPlugin
      Overrides:
      getKey in class BaseNotificationPlugin
      Returns:
    • getLanguage

      protected String getLanguage(NotificationInfo message)
      Parameters:
      message -
      Returns:
    • getOrganizationService

      protected org.exoplatform.services.organization.OrganizationService getOrganizationService()
      Overrides:
      getOrganizationService in class BaseNotificationPlugin
    • getTemplateEngine

      public groovy.text.Template getTemplateEngine()
      Get TemplateEngine of plugin
      Returns:
      the TemplateEngine
    • setTemplateEngine

      public void setTemplateEngine(groovy.text.Template engine)
      Set TemplateEngine for plugin
      Parameters:
      engine - the TemplateEngine to set