public class SiteEmailNotificationAnnc
extends org.sakaiproject.util.SiteEmailNotification
implements org.sakaiproject.api.app.scheduler.ScheduledInvocationCommand
SiteEmailNotificationAnnc fills the notification message and headers with details from the announcement message that triggered the notification event.
| Constructor and Description |
|---|
SiteEmailNotificationAnnc()
Construct.
|
SiteEmailNotificationAnnc(String siteId)
Construct.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addSpecialRecipients(List users,
org.sakaiproject.entity.api.Reference ref)
Add to the user list any other users who should be notified about this ref's change.
|
protected void |
disableSecurityAdvisor()
remove recent add SecurityAdvisor from stack
|
protected void |
enableSecurityAdvisorToGetAnnouncement()
Establish a security advisor to allow the "embedded" azg work to occur
with no need for additional security permissions.
|
void |
execute(String opaqueContext)
Implementation of command pattern.
|
protected String |
getFromAddress(org.sakaiproject.event.api.Event event)
Format the announcement notification from address.
|
protected List |
getHeaders(org.sakaiproject.event.api.Event event) |
protected String |
getResourceAbility() |
protected String |
getSubject(org.sakaiproject.event.api.Event event)
Format the announcement notification subject line.
|
protected String |
getTag(String title,
boolean shouldUseHtml) |
protected String |
htmlContent(org.sakaiproject.event.api.Event event) |
protected org.sakaiproject.util.EmailNotification |
makeEmailNotification() |
void |
notify(org.sakaiproject.event.api.Notification notification,
org.sakaiproject.event.api.Event event) |
protected String |
plainTextContent(org.sakaiproject.event.api.Event event) |
void |
setScheduledInvocationManager(org.sakaiproject.api.app.scheduler.ScheduledInvocationManager service)
Inject ScheudledInvocationManager
|
getClone, getRecipients, getTo, getToSite, getToSiteNoReply, refineToSiteMembersdigestRecipients, digestRecipients, findHeader, findHeaderValue, getFrom, getFromEventUser, getFromService, getMessage, getOption, getOption, getSite, getType, htmlEnd, htmlHeaders, htmlPreamble, immediateRecipients, immediateRecipients, isImmediateDeliveryOption, isImmediateDeliveryOption, plainTextHeaders, reNotify, set, set, toXmlpublic SiteEmailNotificationAnnc()
public SiteEmailNotificationAnnc(String siteId)
public void setScheduledInvocationManager(org.sakaiproject.api.app.scheduler.ScheduledInvocationManager service)
protected String getResourceAbility()
getResourceAbility in class org.sakaiproject.util.SiteEmailNotificationpublic void notify(org.sakaiproject.event.api.Notification notification,
org.sakaiproject.event.api.Event event)
notify in interface org.sakaiproject.event.api.NotificationActionnotify in class org.sakaiproject.util.EmailNotificationprotected String htmlContent(org.sakaiproject.event.api.Event event)
htmlContent in class org.sakaiproject.util.EmailNotificationprotected List getHeaders(org.sakaiproject.event.api.Event event)
getHeaders in class org.sakaiproject.util.EmailNotificationprotected String getTag(String title, boolean shouldUseHtml)
getTag in class org.sakaiproject.util.EmailNotificationprotected String getSubject(org.sakaiproject.event.api.Event event)
getSubject in class org.sakaiproject.util.EmailNotificationevent - The event that matched criteria to cause the notification.protected String getFromAddress(org.sakaiproject.event.api.Event event)
event - The event that matched criteria to cause the notification.protected void addSpecialRecipients(List users, org.sakaiproject.entity.api.Reference ref)
addSpecialRecipients in class org.sakaiproject.util.SiteEmailNotificationusers - The user list, already populated based on site visit and resource ability.ref - The entity reference.public void execute(String opaqueContext)
execute in interface org.sakaiproject.api.app.scheduler.ScheduledInvocationCommandopaqueContext - reference (context) for messageprotected void enableSecurityAdvisorToGetAnnouncement()
protected void disableSecurityAdvisor()
protected org.sakaiproject.util.EmailNotification makeEmailNotification()
makeEmailNotification in class org.sakaiproject.util.EmailNotificationprotected String plainTextContent(org.sakaiproject.event.api.Event event)
plainTextContent in class org.sakaiproject.util.EmailNotificationCopyright © 2003-2016 The Sakai Foundation. All Rights Reserved.