Package anderix.mail
Class EmailMessage
java.lang.Object
anderix.mail.EmailMessage
-
Constructor Summary
ConstructorDescriptionEmailMessage
(String smtpHost, int smtpPort, boolean startTLS, String smtpUser, String smtpPassword) EmailMessage
(String smtpHost, int smtpPort, String smtpUser, String smtpPassword) EmailMessage
(String smtpHost, String smtpUser, String smtpPassword) -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
void
void
void
void
void
void
send()
void
void
void
void
void
setSubject
(String subject) void
-
Constructor Details
-
EmailMessage
-
EmailMessage
-
EmailMessage
-
-
Method Details
-
setFrom
- Throws:
javax.mail.internet.AddressException
-
setFrom
- Throws:
javax.mail.internet.AddressException
-
addTo
- Throws:
javax.mail.internet.AddressException
-
addTo
- Throws:
javax.mail.internet.AddressException
-
addCC
- Throws:
javax.mail.internet.AddressException
-
addCC
- Throws:
javax.mail.internet.AddressException
-
addBCC
- Throws:
javax.mail.internet.AddressException
-
addBCC
- Throws:
javax.mail.internet.AddressException
-
setSubject
-
setText
-
attach
-
send
- Throws:
javax.mail.MessagingException
IOException
-
send
public void send(String from, String to, String subject, String text) throws javax.mail.MessagingException, IOException - Throws:
javax.mail.MessagingException
IOException
-
send
public void send(String from, String to, String subject, String text, File attachment) throws javax.mail.MessagingException, IOException - Throws:
javax.mail.MessagingException
IOException
-