Class SendMail
java.lang.Object
org.nuxeo.ecm.automation.core.operations.notification.SendMail
Save the session - TODO remove this?
- Author:
- Bogdan Stefanescu
-
Field Summary
Modifier and TypeFieldDescriptionprotected boolean
protected StringList
protected StringList
protected StringList
static final Composer
Deprecated.protected OperationContext
protected String
static final String
protected boolean
protected String
protected StringList
protected boolean
protected String
protected StringList
protected String
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
addMailBoxInfo
(Mailer.Message msg, Map<String, Object> map) Deprecated.since 2023.4 unused.protected void
addMailBoxInfoInMessageHeader
(Mailer.Message msg, Mailer.Message.AS as, List<MailBox> persons) asStringList
(List<P> inputList) protected String
createDocUrlWithToken
(String documentUrl, String token) protected Mailer.Message
createMessage
(DocumentModel doc, String message, Map<String, Object> map) Deprecated.since 2023.4 unused.protected void
getBlobs
(DocumentModel doc) protected String
protected String
renderContent
(Map<String, Object> map) run
(DocumentModel doc) protected void
send
(DocumentModel doc)
-
Field Details
-
COMPOSER
Deprecated.since 11.1 due to its static modifier, it messes up tests, instantiateComposer
instead -
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.TemplateException
OperationException
IOException
-
getContent
- Throws:
OperationException
IOException
-
send
protected void send(DocumentModel doc) throws freemarker.template.TemplateException, OperationException, IOException - Throws:
freemarker.template.TemplateException
OperationException
IOException
-
createDocUrlWithToken
-
addMailBoxInfo
@Deprecated(since="2023.4") protected void addMailBoxInfo(Mailer.Message msg, Map<String, Object> map) throws javax.mail.MessagingExceptionDeprecated.since 2023.4 unused.send(DocumentModel)
now uses aMailMessage.Builder
- Throws:
javax.mail.MessagingException
- Since:
- 5.9.1
-
addMailBoxInfoInMessageHeader
protected void addMailBoxInfoInMessageHeader(Mailer.Message msg, Mailer.Message.AS as, List<MailBox> persons) throws javax.mail.MessagingException - Throws:
javax.mail.MessagingException
- Since:
- 5.9.1
-
createMessage
@Deprecated(since="2023.4") protected Mailer.Message createMessage(DocumentModel doc, String message, Map<String, Object> map) throws javax.mail.MessagingException, freemarker.template.TemplateException, IOExceptionDeprecated.since 2023.4 unused.send(DocumentModel)
now uses aMailMessage.Builder
- Throws:
javax.mail.MessagingException
freemarker.template.TemplateException
IOException
-
renderContent
protected String renderContent(Map<String, Object> map) throws IOException, OperationException, freemarker.template.TemplateException- Throws:
IOException
OperationException
freemarker.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
-
Composer
instead