Package org.alfresco.email.dsl.smtp
Class ComposeMessage
- java.lang.Object
-
- org.alfresco.email.dsl.smtp.ComposeMessage
-
public class ComposeMessage extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ComposeMessage(SmtpWrapper smtpProtocol, javax.mail.Session session)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SmtpWrappersendMail()ComposeMessagewithAttachments(java.io.File... files)ComposeMessagewithBody(java.lang.String body)ComposeMessagewithRecipients(java.lang.String commaSeparatedRecipients)commaSeparatedRecipients = "a1@test.com, a2@test.com")ComposeMessagewithSubject(java.lang.String subject)
-
-
-
Constructor Detail
-
ComposeMessage
public ComposeMessage(SmtpWrapper smtpProtocol, javax.mail.Session session)
-
-
Method Detail
-
withRecipients
public ComposeMessage withRecipients(java.lang.String commaSeparatedRecipients) throws java.lang.Exception
commaSeparatedRecipients = "a1@test.com, a2@test.com")- Parameters:
commaSeparatedRecipients-- Returns:
- Throws:
java.lang.Exception
-
withSubject
public ComposeMessage withSubject(java.lang.String subject) throws java.lang.Exception
- Throws:
java.lang.Exception
-
withBody
public ComposeMessage withBody(java.lang.String body) throws java.lang.Exception
- Throws:
java.lang.Exception
-
withAttachments
public ComposeMessage withAttachments(java.io.File... files) throws java.lang.Exception
- Throws:
java.lang.Exception
-
sendMail
public SmtpWrapper sendMail() throws java.lang.Exception
- Throws:
java.lang.Exception
-
-