public interface Emailer
| Modifier and Type | Method and Description |
|---|---|
void |
sendEmail(MailInfo mailInfo)
Sends an email to the email addresses provided in the
MailInfo, using the sender from the passed in MailInfo,
or if not provided, the one in MailSettings. |
void |
sendEmail(java.lang.String subject,
java.util.List<java.lang.String> mailTo,
java.lang.String message)
Sends an email to a collection of email addresses, using the sender from
MailSettings |
void |
sendEmail(java.lang.String subject,
java.lang.String mailTo,
java.lang.String message)
Sends an email to a single email address, using the sender from
MailSettings |
void sendEmail(java.lang.String subject,
java.lang.String mailTo,
java.lang.String message)
throws javax.mail.MessagingException
MailSettingssubject - the subject of the email to be sentmailTo - the email address to which we want to send the emailmessage - the content/body of the email to be sentjavax.mail.MessagingException - when the email is malformed or SMTP setup is not correct.void sendEmail(java.lang.String subject,
java.util.List<java.lang.String> mailTo,
java.lang.String message)
throws javax.mail.MessagingException
MailSettingssubject - the subject of the email to be sentmailTo - the email addresses to which we want to send the emailmessage - the content/body of the email to be sentjavax.mail.MessagingException - when the email is malformed or SMTP setup is not correct.void sendEmail(MailInfo mailInfo) throws javax.mail.MessagingException
MailInfo, using the sender from the passed in MailInfo,
or if not provided, the one in MailSettings. Provides much more functionality than
either sendEmail(String, List, String) or sendEmail(String, String, String)mailInfo - the object containing all the information about the email to be sentjavax.mail.MessagingException - when the email is malformed or SMTP setup is not correct.