Class AbstractCommentNotifyMentionsObserver<T extends AmetysObject>
java.lang.Object
org.ametys.runtime.plugin.component.AbstractLogEnabled
org.ametys.cms.repository.mentions.AbstractNotifyMentionsObserver<T>
org.ametys.cms.repository.comment.contributor.AbstractCommentNotifyMentionsObserver<T>
- Type Parameters:
 T- type of theAmetysObject
- All Implemented Interfaces:
 AsyncObserver,Observer,LogEnabled,Prioritizable,Supporter<Event>,Component,Serviceable
- Direct Known Subclasses:
 AbstractNotifyWorkspacesCommentMentionsObserver,NotifyContentMentionsObserver
public abstract class AbstractCommentNotifyMentionsObserver<T extends AmetysObject>
extends AbstractNotifyMentionsObserver<T>
Abstract observer to send mails to mentioned users in contributor comments of 
AmetysObject- 
Nested Class Summary
Nested classes/interfaces inherited from class org.ametys.cms.repository.mentions.AbstractNotifyMentionsObserver
AbstractNotifyMentionsObserver.LinkToAmetysObject, AbstractNotifyMentionsObserver.MentionableObject - 
Field Summary
Fields inherited from class org.ametys.cms.repository.mentions.AbstractNotifyMentionsObserver
_currentUserProvider, _i18nUtils, _mentionUtils, _resolvedUsers, _resolver, _userLanguagesManager, _userManagerFields inherited from interface org.ametys.core.observation.Observer
MAX_PRIORITY, MIN_PRIORITY - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionprotected abstract String_getAmetysObjectTitle(T ametysObject) Get the title to display in the mailprotected AbstractComment_getComment(T ametysObject, Map<String, Object> arguments) Get the comment form the argumentsprotected I18nizableTextGet the type of message to display before the messageprotected I18nizableText_getMailSubject(AbstractNotifyMentionsObserver.MentionableObject mentionableObject) Retrieves the notification mail's subjectprotected String_transformSyntaxTextToReadableTextWithColors(String syntaxText, UserIdentity recipient) Transform syntax text to readable text with colors according to whether the recipient is the one being tagged or notMethods inherited from class org.ametys.cms.repository.mentions.AbstractNotifyMentionsObserver
_canSendMailToMentionedUser, _createBody, _getMailMessage, _getMailTitle, _getMentionableObjectFromArguments, _sendMail, _sendMailToMentionedUsers, getPriority, getStandardMailBodyHelper, observe, serviceMethods inherited from class org.ametys.runtime.plugin.component.AbstractLogEnabled
getLogger, setLoggerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ametys.core.observation.AsyncObserver
parallelizable 
- 
Constructor Details
- 
AbstractCommentNotifyMentionsObserver
 
 - 
 - 
Method Details
- 
_transformSyntaxTextToReadableTextWithColors
protected String _transformSyntaxTextToReadableTextWithColors(String syntaxText, UserIdentity recipient) Description copied from class:AbstractNotifyMentionsObserverTransform syntax text to readable text with colors according to whether the recipient is the one being tagged or not- Specified by:
 _transformSyntaxTextToReadableTextWithColorsin classAbstractNotifyMentionsObserver<T extends AmetysObject>- Parameters:
 syntaxText- the syntax textrecipient- the recipient- Returns:
 - the readable text
 
 - 
_getMailMessageType
Description copied from class:AbstractNotifyMentionsObserverGet the type of message to display before the message- Specified by:
 _getMailMessageTypein classAbstractNotifyMentionsObserver<T extends AmetysObject>- Returns:
 - the message type
 
 - 
_getMailSubject
protected I18nizableText _getMailSubject(AbstractNotifyMentionsObserver.MentionableObject mentionableObject) Description copied from class:AbstractNotifyMentionsObserverRetrieves the notification mail's subject- Specified by:
 _getMailSubjectin classAbstractNotifyMentionsObserver<T extends AmetysObject>- Parameters:
 mentionableObject- the mentionable object- Returns:
 - the notification mail's subject
 
 - 
_getComment
Get the comment form the arguments- Parameters:
 ametysObject- the ametys objectarguments- the arguments map- Returns:
 - the comment
 
 - 
_getAmetysObjectTitle
Get the title to display in the mail- Parameters:
 ametysObject- the ametys object- Returns:
 - the ametys object title
 
 
 -