|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectinfo.fingo.util.Internet
public class Internet
Internet related helper functions.
This class need javax.mail library to work
| Field Summary | |
|---|---|
static int |
PRIORITY_HIGH
The email priority: high = 1 |
static int |
PRIORITY_LOW
The email priority: low = 3 |
static int |
PRIORITY_NORMAL
The email priority: normal = 2 |
| Constructor Summary | |
|---|---|
Internet()
|
|
| Method Summary | |
|---|---|
static boolean |
checkEmail(java.lang.String email)
Check if email address is correct |
static void |
sendEmail(java.lang.String server,
java.lang.String from,
java.lang.String[] to,
java.lang.String[] cc,
java.lang.String[] bcc,
java.lang.String subject,
java.lang.String body,
java.lang.String encoding,
boolean isHtml)
Sends an email to many recipients. |
static void |
sendEmail(java.lang.String server,
java.lang.String from,
java.lang.String[] to,
java.lang.String[] cc,
java.lang.String[] bcc,
java.lang.String subject,
java.lang.String body,
java.lang.String encoding,
boolean isHtml,
int priority)
Sends an email to many recipients with the specified priority. |
static void |
sendEmail(java.lang.String server,
java.lang.String from,
java.lang.String to,
java.lang.String subject,
java.lang.String body,
boolean isHtml)
Sends an email. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int PRIORITY_LOW
public static final int PRIORITY_NORMAL
public static final int PRIORITY_HIGH
| Constructor Detail |
|---|
public Internet()
| Method Detail |
|---|
public static boolean checkEmail(java.lang.String email)
email - email address
true if OK, false else
public static void sendEmail(java.lang.String server,
java.lang.String from,
java.lang.String to,
java.lang.String subject,
java.lang.String body,
boolean isHtml)
throws java.lang.Exception
server - the smtp host to send the message.from - the 'from' email addressto - target recipient emailsubject - the message subjectbody - the email bodyisHtml - the format indicator: true for HTML, false for text
java.lang.Exception
public static void sendEmail(java.lang.String server,
java.lang.String from,
java.lang.String[] to,
java.lang.String[] cc,
java.lang.String[] bcc,
java.lang.String subject,
java.lang.String body,
java.lang.String encoding,
boolean isHtml)
throws java.lang.Exception
server - the smtp host to send the message.from - the 'from' email addressto - target recipients' emailscc - carbon copy reciepients' emailsbcc - blind carbon copy recipients' emailssubject - the message subjectbody - the email bodyencoding - encoding for the messageisHtml - the format indicator: true for HTML, false for text
java.lang.Exception
public static void sendEmail(java.lang.String server,
java.lang.String from,
java.lang.String[] to,
java.lang.String[] cc,
java.lang.String[] bcc,
java.lang.String subject,
java.lang.String body,
java.lang.String encoding,
boolean isHtml,
int priority)
throws java.lang.Exception
server - the smtp host to send the message.from - the 'from' email addressto - target recipients' emailscc - carbon copy reciepients' emailsbcc - blind carbon copy recipients' emailssubject - the message subjectbody - the email bodyencoding - encoding for the messageisHtml - the format indicator: true for HTML, false for textpriority - the email priority; one of the PRIORITY_XXXconstants
java.lang.Exception
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||