Class SendMail
java.lang.Object
org.nuxeo.ecm.automation.core.operations.notification.SendMail
- Author:
- Bogdan Stefanescu
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected booleanprotected StringListprotected StringListprotected StringListstatic final ComposerDeprecated.protected OperationContextprotected Stringstatic final Stringprotected booleanprotected Stringprotected StringListprotected booleanprotected Stringprotected StringListprotected String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddMailBoxInfo(Mailer.Message msg, Map<String, Object> map) Deprecated.since 2023.4 unused.protected voidaddMailBoxInfoInMessageHeader(Mailer.Message msg, Mailer.Message.AS as, List<MailBox> persons) asStringList(List<P> inputList) protected StringcreateDocUrlWithToken(String documentUrl, String token) protected Mailer.MessagecreateMessage(DocumentModel doc, String message, Map<String, Object> map) Deprecated.since 2023.4 unused.protected voidgetBlobs(DocumentModel doc) protected Stringprotected StringrenderContent(Map<String, Object> map) run(DocumentModel doc) protected voidsend(DocumentModel doc)
-
Field Details
-
COMPOSER
Deprecated.since 11.1 due to its static modifier, it messes up tests, instantiateComposerinstead -
ID
- See Also:
-
ctx
-
from
-
to
-
cc
- Since:
- 5.9.1
-
bcc
- Since:
- 5.9.1
-
replyto
- Since:
- 5.9.1
-
subject
-
message
-
asHtml
protected boolean asHtml -
blobXpath
-
rollbackOnError
protected boolean rollbackOnError -
isStrict
protected boolean isStrict- Since:
- 5.9.1
-
viewId
-
-
Constructor Details
-
SendMail
public SendMail()
-
-
Method Details
-
run
public DocumentModel run(DocumentModel doc) throws freemarker.template.TemplateException, OperationException, IOException - Throws:
freemarker.template.TemplateExceptionOperationExceptionIOException
-
getContent
- Throws:
OperationExceptionIOException
-
send
protected void send(DocumentModel doc) throws freemarker.template.TemplateException, OperationException, IOException - Throws:
freemarker.template.TemplateExceptionOperationExceptionIOException
-
createDocUrlWithToken
-
addMailBoxInfo
@Deprecated(since="2023.4") protected void addMailBoxInfo(Mailer.Message msg, Map<String, Object> map) throws jakarta.mail.MessagingExceptionDeprecated.since 2023.4 unused.send(DocumentModel)now uses aMailMessage.Builder- Throws:
jakarta.mail.MessagingException- Since:
- 5.9.1
-
addMailBoxInfoInMessageHeader
protected void addMailBoxInfoInMessageHeader(Mailer.Message msg, Mailer.Message.AS as, List<MailBox> persons) throws jakarta.mail.MessagingException - Throws:
jakarta.mail.MessagingException- Since:
- 5.9.1
-
createMessage
@Deprecated(since="2023.4") protected Mailer.Message createMessage(DocumentModel doc, String message, Map<String, Object> map) throws jakarta.mail.MessagingException, freemarker.template.TemplateException, IOExceptionDeprecated.since 2023.4 unused.send(DocumentModel)now uses aMailMessage.Builder- Throws:
jakarta.mail.MessagingExceptionfreemarker.template.TemplateExceptionIOException
-
renderContent
protected String renderContent(Map<String, Object> map) throws IOException, OperationException, freemarker.template.TemplateException- Throws:
IOExceptionOperationExceptionfreemarker.template.TemplateException
-
asStringList
-
getBlobs
-
getBlob
- Parameters:
o- : the object to introspect to find a blobblobs- : the Blob list where the blobs are put during property introspection- Since:
- 5.7
-
Composerinstead