public interface EmailSender
EmailSender
object defines the state of
an email and allows sending it via SMTP. This is not compatible with the standard 4GL because
it is an extension that is specific to FWD.Modifier and Type | Method and Description |
---|---|
logical |
addBccAddress(character addr)
Add a BCC address to the list of recipients.
|
logical |
addBccAddress(java.lang.String addr)
Add a BCC address to the list of recipients.
|
logical |
addCcAddress(character addr)
Add a CC address to the list of recipients.
|
logical |
addCcAddress(java.lang.String addr)
Add a CC address to the list of recipients.
|
logical |
addToAddress(character addr)
Add a TO address to the list of recipients.
|
logical |
addToAddress(java.lang.String addr)
Add a TO address to the list of recipients.
|
logical |
attachFile(character file)
Attach the specified file to the email.
|
logical |
attachFile(java.lang.String file)
Attach the specified file to the email.
|
logical |
attachURL(character url)
Attach the file specified by the given URL to the email.
|
logical |
attachURL(java.lang.String url)
Attach the file specified by the given URL to the email.
|
logical |
clearAttachmentsList()
Clear the list of attachments.
|
logical |
clearBccAddressList()
Clear the list of BCC recipients.
|
logical |
clearCcAddressList()
Clear the list of CC recipients.
|
logical |
clearEmbeddedImageList()
Clear the list of embedded images.
|
logical |
clearToAddressList()
Clear the list of TO recipients.
|
character |
embedImageByFile(character file)
Embed the image specified by the given file and return the content ID needed to substitute
into the HTML (in an IMG tag).
|
character |
embedImageByFile(java.lang.String file)
Embed the image specified by the given file and return the content ID needed to substitute
into the HTML (in an IMG tag).
|
character |
embedImageByURL(character url)
Embed the image specified by the given URL and return the content ID needed to substitute
into the HTML (in an IMG tag).
|
character |
embedImageByURL(java.lang.String url)
Embed the image specified by the given URL and return the content ID needed to substitute
into the HTML (in an IMG tag).
|
character[] |
getAttachmentsList()
Obtain the list of attachments.
|
character[] |
getBccAddressList()
Obtain the list of BCC recipients.
|
character[] |
getCcAddressList()
Obtain the list of CC recipients.
|
character |
getConnectionType()
Gets the connection type for the SMTP communications session.
|
character[] |
getEmbeddedImageList()
Obtain the list of embedded image file and URL names.
|
character |
getSmtpFrom()
Gets the FROM address.
|
character |
getSmtpHost()
Gets the host for the SMTP server.
|
character |
getSmtpHtmlBody()
Gets the HTML body contents.
|
character |
getSmtpPassword()
Gets the password for authenticating with the SMTP server.
|
character |
getSmtpPort()
Gets the port for the SMTP server.
|
character |
getSmtpReplyTo()
Gets the REPLY-TO address.
|
character |
getSmtpSubject()
Gets the SUBJECT line.
|
character |
getSmtpTextBody()
Gets the TEXT body contents.
|
character |
getSmtpUser()
Gets the userid for authenticating with the SMTP server.
|
character[] |
getToAddressList()
Obtain the list of TO recipients.
|
logical |
isSmtpValidate()
Returns the state of the SMTP-VALIDATE attribute, which determines if the SMTP server
certificate is validated during an SSL or STARTTLS connection.
|
logical |
send()
Send the email.
|
void |
setConnectionType(character type)
Sets the connection type for the SMTP communications session.
|
void |
setConnectionType(java.lang.String type)
Sets the connection type for the SMTP communications session.
|
void |
setSmtpFrom(character from)
Sets the FROM address.
|
void |
setSmtpFrom(java.lang.String from)
Sets the FROM address.
|
void |
setSmtpHost(character host)
Sets the host for the SMTP server.
|
void |
setSmtpHost(java.lang.String host)
Sets the host for the SMTP server.
|
void |
setSmtpHtmlBody(character html)
Sets the HTML body contents.
|
void |
setSmtpHtmlBody(java.lang.String html)
Sets the HTML body contents.
|
void |
setSmtpPassword(character password)
Sets the password for authenticating with the SMTP server.
|
void |
setSmtpPassword(java.lang.String password)
Sets the password for authenticating with the SMTP server.
|
void |
setSmtpPort(character port)
Sets the port for the SMTP server.
|
void |
setSmtpPort(java.lang.String port)
Sets the port for the SMTP server.
|
void |
setSmtpReplyTo(character replyTo)
Sets the REPLY-TO address.
|
void |
setSmtpReplyTo(java.lang.String replyTo)
Sets the REPLY-TO address.
|
void |
setSmtpSubject(character subject)
Sets the SUBJECT line.
|
void |
setSmtpSubject(java.lang.String subject)
Sets the SUBJECT line.
|
void |
setSmtpTextBody(character text)
Sets the TEXT body contents.
|
void |
setSmtpTextBody(java.lang.String text)
Sets the TEXT body contents.
|
void |
setSmtpUser(character userid)
Sets the userid for authenticating with the SMTP server.
|
void |
setSmtpUser(java.lang.String userid)
Sets the userid for authenticating with the SMTP server.
|
void |
setSmtpValidate(boolean validate)
Setter for SMTP-VALIDATE attribute, which determines if the SMTP server certificate is
validated during an SSL or STARTTLS connection.
|
void |
setSmtpValidate(logical validate)
Setter for SMTP-VALIDATE attribute, which determines if the SMTP server certificate is
validated during an SSL or STARTTLS connection.
|
character getConnectionType()
void setConnectionType(character type)
type
- The connection type which must be "UNENCRYPTED", "STARTTLS_WHEN_AVAILABLE",
"STARTTLS_REQUIRED" or "SSL". Must not be null
or unknown.void setConnectionType(java.lang.String type)
type
- The connection type which must be "UNENCRYPTED", "STARTTLS_WHEN_AVAILABLE",
"STARTTLS_REQUIRED" or "SSL". Must not be null
.character getSmtpHost()
void setSmtpHost(character host)
host
- The name or IP address of the SMTP server. Must not be null
or unknown.void setSmtpHost(java.lang.String host)
host
- The name or IP address of the SMTP server. Must not be null
.character getSmtpPort()
void setSmtpPort(character port)
port
- The port used by the SMTP server.void setSmtpPort(java.lang.String port)
port
- The port used by the SMTP server.character getSmtpUser()
void setSmtpUser(character userid)
userid
- The userid for authentication.void setSmtpUser(java.lang.String userid)
userid
- The userid for authentication.character getSmtpPassword()
void setSmtpPassword(character password)
password
- The password for authentication.void setSmtpPassword(java.lang.String password)
password
- The password for authentication.logical isSmtpValidate()
void setSmtpValidate(boolean validate)
validate
- true
to validate the server certificate.void setSmtpValidate(logical validate)
validate
- true
to validate the server certificate.character getSmtpFrom()
void setSmtpFrom(character from)
from
- The FROM address.void setSmtpFrom(java.lang.String from)
from
- The FROM address.character getSmtpReplyTo()
void setSmtpReplyTo(character replyTo)
replyTo
- The REPLY-TO address.void setSmtpReplyTo(java.lang.String replyTo)
replyTo
- The REPLY-TO address.character getSmtpSubject()
void setSmtpSubject(character subject)
subject
- The SUBJECT line.void setSmtpSubject(java.lang.String subject)
subject
- The SUBJECT line.character getSmtpHtmlBody()
void setSmtpHtmlBody(character html)
html
- The HTML body contents.void setSmtpHtmlBody(java.lang.String html)
html
- The HTML body contents.character getSmtpTextBody()
void setSmtpTextBody(character text)
text
- The TEXT body contents.void setSmtpTextBody(java.lang.String text)
text
- The TEXT body contents.logical addToAddress(character addr)
addr
- The TO address.logical addToAddress(java.lang.String addr)
addr
- The TO address.logical addCcAddress(character addr)
addr
- The CC address.logical addCcAddress(java.lang.String addr)
addr
- The CC address.logical addBccAddress(character addr)
addr
- The BCC address.logical addBccAddress(java.lang.String addr)
addr
- The BCC address.logical attachFile(character file)
file
- The file to attach.logical attachFile(java.lang.String file)
file
- The file to attach.logical attachURL(character url)
url
- The resource to attach.logical attachURL(java.lang.String url)
url
- The resource to attach.logical clearAttachmentsList()
logical clearBccAddressList()
logical clearCcAddressList()
logical clearEmbeddedImageList()
logical clearToAddressList()
character embedImageByFile(character file)
file
- The resource to attach.character embedImageByFile(java.lang.String file)
file
- The resource to attach.character embedImageByURL(character url)
url
- The resource to attach.character embedImageByURL(java.lang.String url)
url
- The resource to attach.character[] getAttachmentsList()
character[] getBccAddressList()
character[] getCcAddressList()
character[] getEmbeddedImageList()
character[] getToAddressList()
logical send() throws ErrorConditionException
true
if the send succeeded.ErrorConditionException
- On any failure, unless silent error mode is enabled.