|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
The MailService Interface provides methods for sending text and html mails with or without attachments.
Copyright 2002 Sapient
| Method Summary | |
void |
sendMail(MailDataObject mailDataObject)
Sends an email with the parameters specified in mail data object. |
| Method Detail |
public void sendMail(MailDataObject mailDataObject)
throws MailFailureException
Sends an email with the parameters specified in mail data object.
E.x MailDataObject mailDataObject = new MailDataObject();
mailDataObject.addTo("someone@somewhere.com", "someone");
mailDataObject.setFrom("ejfw4@sapient.com", "ejfw4");
mailDataObject.setSubject("Hello");
mailDataObject.setBody("A simple plain text email",
MailContentTypeEnum.PLAIN_TEXT);
// Fetch the mail component
MailService mailService = (MailService) Lookup.getInstance().
fetchComponent("/email/test/testEmail");
mailService.sendMail(mailDataObject);
mailDataObject - Encapsulates all the parameters required to send
a mail.
MailFailureException - Thrown if unable to send the mail.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||