|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.melati.util.Email
public final class Email
Send an email to one or more recipients with or without attachments.
| Field Summary | |
|---|---|
static java.lang.String |
SMTPSERVER
Property key for the SMTP server. |
| Method Summary | |
|---|---|
static java.lang.String |
mailAddress(java.lang.String name,
java.lang.String email)
|
static void |
send(java.lang.String smtpServer,
java.lang.String from,
java.lang.String to,
java.lang.String replyto,
java.lang.String subject,
java.lang.String text)
Send the email. |
static void |
sendAsHtmlWithAttachments(java.lang.String smtpServer,
java.lang.String from,
java.lang.String to,
java.lang.String replyto,
java.lang.String subject,
java.lang.String plainText,
java.lang.String htmlText,
java.io.File[] referenced,
java.io.File[] attachments)
Send HTML message with attachments. |
static void |
sendToList(java.lang.String smtpServer,
java.lang.String from,
java.lang.String[] toList,
java.lang.String replyto,
java.lang.String subject,
java.lang.String message)
Send the email to a list of recipients. |
static void |
sendWithAttachments(java.lang.String smtpServer,
java.lang.String from,
java.lang.String to,
java.lang.String replyto,
java.lang.String subject,
java.lang.String text,
java.io.File[] attachments)
Send message with attachments. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static java.lang.String SMTPSERVER
| Method Detail |
|---|
public static void send(java.lang.String smtpServer,
java.lang.String from,
java.lang.String to,
java.lang.String replyto,
java.lang.String subject,
java.lang.String text)
throws EmailException,
java.io.IOException
smtpServer - name of SMTP server to usefrom - email address and optionally name of senderto - email address and optionally name of recipientreplyto - email address and optionally name to reply tosubject - subject of messagetext - text body of email
EmailException
java.io.IOException
public static void sendToList(java.lang.String smtpServer,
java.lang.String from,
java.lang.String[] toList,
java.lang.String replyto,
java.lang.String subject,
java.lang.String message)
throws EmailException,
java.io.IOException
smtpServer - name of SMTP server to usefrom - email address and optionally name of sendertoList - list of email addresses and optionally names of recipientsreplyto - email address and optionally name to reply tosubject - subject of messagemessage - text body of email
EmailException
java.io.IOException
public static void sendWithAttachments(java.lang.String smtpServer,
java.lang.String from,
java.lang.String to,
java.lang.String replyto,
java.lang.String subject,
java.lang.String text,
java.io.File[] attachments)
throws EmailException,
java.io.IOException
smtpServer - name of SMTP server to usefrom - email address and optionally name of senderto - email address and optionally name of recipientreplyto - email address and optionally name to reply tosubject - subject of messagetext - text body of emailattachments - Array of files to attach
EmailException
java.io.IOException
public static void sendAsHtmlWithAttachments(java.lang.String smtpServer,
java.lang.String from,
java.lang.String to,
java.lang.String replyto,
java.lang.String subject,
java.lang.String plainText,
java.lang.String htmlText,
java.io.File[] referenced,
java.io.File[] attachments)
throws EmailException,
java.io.IOException
smtpServer - name of SMTP server to usefrom - email address and optionally name of senderto - email address and optionally name of recipientreplyto - email address and optionally name to reply tosubject - subject of messageplainText - text body of emailhtmlText - HTML body of emailreferenced - Array of Files referenced withing the HTML bodyattachments - Array of files to attach
EmailException
java.io.IOException
public static java.lang.String mailAddress(java.lang.String name,
java.lang.String email)
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||