public abstract class AbstractNotificationPlugin
extends org.exoplatform.container.component.BaseComponentPlugin
| Constructor and Description |
|---|
AbstractNotificationPlugin(org.exoplatform.container.xml.InitParams initParams) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
buildDigest(NotificationContext ctx,
Writer writer)
Makes digest message
|
MessageInfo |
buildMessage(NotificationContext ctx)
Makes massage
|
NotificationInfo |
buildNotification(NotificationContext ctx)
Makes notification
|
void |
end(NotificationContext ctx)
End the plug in
|
abstract String |
getId()
Gets Notification Plug in key
|
NotificationKey |
getKey()
Creates the key for NotificationPlugin
|
protected String |
getLanguage(NotificationInfo message) |
protected org.exoplatform.services.organization.OrganizationService |
getOrganizationService() |
List<PluginConfig> |
getPluginConfigs() |
groovy.text.Template |
getTemplateEngine()
Get TemplateEngine of plugin
|
abstract boolean |
isValid(NotificationContext ctx)
Check, for each plugin, if we will send notification
|
protected abstract boolean |
makeDigest(NotificationContext ctx,
Writer writer)
Makes the Digest message from given NotificationMessage what keep inside NotificationContext
|
protected abstract MessageInfo |
makeMessage(NotificationContext ctx)
Makes the MessageInfor from given NotificationMessage what keep inside NotificationContext
|
protected abstract NotificationInfo |
makeNotification(NotificationContext ctx)
Makes MessageInfo from given information what keep inside NotificationContext
|
void |
setTemplateEngine(groovy.text.Template engine)
Set TemplateEngine for plugin
|
void |
start(NotificationContext ctx)
Start the plug in
|
public AbstractNotificationPlugin(org.exoplatform.container.xml.InitParams initParams)
public List<PluginConfig> getPluginConfigs()
public void start(NotificationContext ctx)
context - public void end(NotificationContext ctx)
context - public abstract String getId()
public abstract boolean isValid(NotificationContext ctx)
protected abstract NotificationInfo makeNotification(NotificationContext ctx)
context - protected abstract MessageInfo makeMessage(NotificationContext ctx)
context - protected abstract boolean makeDigest(NotificationContext ctx, Writer writer)
ctx - wtiter - public NotificationInfo buildNotification(NotificationContext ctx)
ctx - public MessageInfo buildMessage(NotificationContext ctx)
ctx - public boolean buildDigest(NotificationContext ctx, Writer writer)
ctx - writer - public NotificationKey getKey()
protected String getLanguage(NotificationInfo message)
message - protected org.exoplatform.services.organization.OrganizationService getOrganizationService()
public groovy.text.Template getTemplateEngine()
public void setTemplateEngine(groovy.text.Template engine)
engine - the TemplateEngine to setCopyright © 2003–2015 eXo Platform SAS. All rights reserved.