Class AbstractWorkspacesActivityNotifier
java.lang.Object
org.ametys.plugins.workspaces.activities.AbstractWorkspacesActivityNotifier
- All Implemented Interfaces:
PluginAware,ActivityNotifier,Contextualizable,Serviceable
- Direct Known Subclasses:
CalendarEventActivityNotifier,DocumentsActivityNotifier,MemberAddedActivityNotifier,MinisiteActivityNotifier,TasksActivityNotifier,ThreadsActivityNotifier,WebContentActivityNotifier
public abstract class AbstractWorkspacesActivityNotifier
extends Object
implements ActivityNotifier, Serviceable, PluginAware, Contextualizable
Abstract class representing a activity notifier for workspaces
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ContextThe contextprotected I18nUtilsThe i18n utilsprotected NotificationPreferencesHelperThe notification preference helperprotected StringThe plugin nameprotected ProjectManagerThe project managerprotected RenderingContextHandlerThe rendering context handlerprotected AmetysObjectResolverThe Ametys Object resolverprotected RightManagerThe right managerprotected SourceResolverThe source resolverprotected UserManagerThe user manager -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String_getSubjectI18nKey(Activity activity) Get the subject i18n keyvoidcontextualize(Context context) abstract StringgetMailBodyURI(Activity activity) Get the URI to resolve to get the mail bodygetMailHtmlBody(Activity activity) Get the mail body as html from the activitygetMailSubject(Activity activity) Get the mail subject from the activitygetMailTextBody(Activity activity) Get the mail body to text format from the activitygetSubjectI18nParams(Activity activity) Get the subject i18n parametersabstract AmetysObjectgetTargetAmetysObject(Activity activity) Retrieve the ametys object targeted by this activity.getUsersEmailToNotify(Activity activity) Get the list of user email to notify for a given activityvoidservice(ServiceManager manager) voidsetPluginInfo(String pluginName, String featureName, String id) Sets the plugin info relative to the current component.
Note : The feature name may be null if the targeted component in declared at plugin level.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ametys.web.activities.notify.ActivityNotifier
isAsync, support
-
Field Details
-
_rightManager
The right manager -
_notificationPreferenceHelper
The notification preference helper -
_userManager
The user manager -
_projectManager
The project manager -
_i18nUtils
The i18n utils -
_renderingContextHandler
The rendering context handler -
_srcResolver
The source resolver -
_resolver
The Ametys Object resolver -
_pluginName
The plugin name -
_context
The context
-
-
Constructor Details
-
AbstractWorkspacesActivityNotifier
public AbstractWorkspacesActivityNotifier()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Throws:
ServiceException
-
contextualize
- Specified by:
contextualizein interfaceContextualizable- Throws:
ContextException
-
setPluginInfo
Description copied from interface:PluginAwareSets the plugin info relative to the current component.
Note : The feature name may be null if the targeted component in declared at plugin level.- Specified by:
setPluginInfoin interfacePluginAware- Parameters:
pluginName- Unique identifier for the plugin hosting the extensionfeatureName- Unique feature identifier (unique for a given pluginName)id- Unique identifier of this component
-
getUsersEmailToNotify
Description copied from interface:ActivityNotifierGet the list of user email to notify for a given activity- Specified by:
getUsersEmailToNotifyin interfaceActivityNotifier- Parameters:
activity- the activity- Returns:
- the list of user email to notify
-
getTargetAmetysObject
Retrieve the ametys object targeted by this activity. This method is intended for right computation purposes.- Parameters:
activity- the activity- Returns:
- the target
-
getMailSubject
Description copied from interface:ActivityNotifierGet the mail subject from the activity- Specified by:
getMailSubjectin interfaceActivityNotifier- Parameters:
activity- the activity- Returns:
- the mail subject
-
_getSubjectI18nKey
Get the subject i18n key- Parameters:
activity- the activity- Returns:
- the subject i18n key
-
getSubjectI18nParams
Get the subject i18n parameters- Parameters:
activity- the activity- Returns:
- the subject i18n parameters
-
getMailTextBody
Description copied from interface:ActivityNotifierGet the mail body to text format from the activity- Specified by:
getMailTextBodyin interfaceActivityNotifier- Parameters:
activity- the activity- Returns:
- the mail body to text format. Can be null.
-
getMailHtmlBody
Description copied from interface:ActivityNotifierGet the mail body as html from the activity- Specified by:
getMailHtmlBodyin interfaceActivityNotifier- Parameters:
activity- the activity- Returns:
- the mail body as html. Can be null.
-
getMailBodyURI
Get the URI to resolve to get the mail body- Parameters:
activity- the activity- Returns:
- the uri
-