public class MailNotification extends java.lang.Object implements IMailNotification
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
PROP_HOST |
protected static java.lang.String |
PROP_SMTP_SUBSTORE |
Constructor and Description |
---|
MailNotification() |
Modifier and Type | Method and Description |
---|---|
void |
sendNotification()
send one message to one or more addressees
|
void |
setContent(java.lang.String content)
sets the content of the email
|
void |
setContentType(java.lang.String contentType)
sets the "Content-Type" field
|
void |
setFrom(java.lang.String from)
sets the "From" field
|
void |
setSubject(java.lang.String subject)
sets the "Subject" field
|
void |
setTo(java.lang.String to)
sets the recipient's email address
|
void |
setTo(java.util.Vector addresses)
sets the recipients' email addresses
|
protected static final java.lang.String PROP_SMTP_SUBSTORE
protected static final java.lang.String PROP_HOST
public void sendNotification() throws java.io.IOException, ENotificationException
sendNotification
in interface IMailNotification
java.io.IOException
ENotificationException
public void setFrom(java.lang.String from)
setFrom
in interface IMailNotification
from
- email address of the senderpublic void setSubject(java.lang.String subject)
setSubject
in interface IMailNotification
subject
- subject of the emailpublic void setContentType(java.lang.String contentType)
setContentType
in interface IMailNotification
contentType
- content type of the emailpublic void setContent(java.lang.String content)
setContent
in interface IMailNotification
content
- the message contentpublic void setTo(java.util.Vector addresses)
setTo
in interface IMailNotification
addresses
- a list of email addresses of the recipientspublic void setTo(java.lang.String to)
setTo
in interface IMailNotification
to
- address of the recipient email address