Class EmailDeliverer
java.lang.Object
com.webmethods.caf.faces.data.email.EmailDeliverer
Simple Provider to make it easy to send email through the JavaMail support
provided by the server.
- Since:
- 8.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static class
Inner class to EmailDeliverer. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
addExtraBodyParts
(MimeMultipart multipart) Subclasses may override to embed images or other attachments in the mime message.protected DataSource
Factory method that can be overridden to provide a different implementation.Action handler that delivers an email message given the specified data.Get the blind copy addresses for this email.getBody()
Get the body text for this email.Get the carbon copy addresses for this email.Get the content type for this email.Get the from address for this email.Set the reply to address for this email.Get the sender address for this email.Get the session JNDI name.Get the subject text for this email.Get the to addresses for this email.void
setBccAddresses
(String bccAddresses) Set the blind copy addresses for this email.void
Set the body text for this email.void
setCcAddresses
(String ccAddresses) Set the carbon copy addresses for this email.void
setContentType
(String contentType) Set the content type for this email.void
setErrorHandler
(IErrorHandler errorHandler) void
setFromAddress
(String fromAddress) Set the from address for this email.void
setReplyToAddress
(String replyToAddress) Set the reply to address for this email.void
setSenderAddress
(String senderAddress) Set the sender address for this email.void
setSessionJNDIName
(String sessionJNDIName) Set the session JNDI name.void
setSubject
(String subject) Set the subject text for this email.void
setToAddresses
(String toAddresses) Set the to addresses for this email.
-
Field Details
-
errorHandler
-
sessionJNDIName
-
authTypeJNDIName
-
toAddresses
-
ccAddresses
-
bccAddresses
-
replyToAddress
-
subject
-
body
-
contentType
-
fromAddress
-
senderAddress
-
-
Constructor Details
-
EmailDeliverer
public EmailDeliverer()
-
-
Method Details
-
getErrorHandler
-
setErrorHandler
-
getSessionJNDIName
Get the session JNDI name. Default is "mail/Session".- Returns:
- The sessionJNDIName
-
setSessionJNDIName
Set the session JNDI name.- Parameters:
sessionJNDIName
- The session JNDI Name.
-
getToAddresses
Get the to addresses for this email.- Returns:
- The to addresses
-
setToAddresses
Set the to addresses for this email.- Parameters:
toAddresses
- The to addresses.
-
getCcAddresses
Get the carbon copy addresses for this email.- Returns:
- String The carbon copy addresses.
-
setCcAddresses
Set the carbon copy addresses for this email.- Parameters:
ccAddresses
- The carbon copy addresses.
-
getBccAddresses
Get the blind copy addresses for this email.- Returns:
- The blind copy addresses.
-
setBccAddresses
Set the blind copy addresses for this email.- Parameters:
bccAddresses
- The blind copy addresses.
-
getFromAddress
Get the from address for this email.- Returns:
- The from address.
-
setFromAddress
Set the from address for this email.- Parameters:
fromAddress
- The from address.
-
getReplyToAddress
Set the reply to address for this email.- Returns:
- The reply to Address.
-
setReplyToAddress
Set the reply to address for this email.- Parameters:
replyToAddress
- The reply to Address.
-
getSenderAddress
Get the sender address for this email.- Returns:
- The sender address.
-
setSenderAddress
Set the sender address for this email.- Parameters:
senderAddress
- The sender address.
-
getSubject
Get the subject text for this email.- Returns:
- The subject text.
-
setSubject
Set the subject text for this email.- Parameters:
subject
- the subject to set
-
getBody
Get the body text for this email.- Returns:
- The body text.
-
setBody
Set the body text for this email.- Parameters:
body
- The body text.
-
getContentType
Get the content type for this email.- Returns:
- The content type.
-
setContentType
Set the content type for this email.- Parameters:
contentType
- The content type.
-
deliverEmail
Action handler that delivers an email message given the specified data.- Returns:
- Always null which will signal JSF to stay on the same UI page
-
addExtraBodyParts
Subclasses may override to embed images or other attachments in the mime message.- Parameters:
multipart
- The mime message.- Throws:
Exception
-
createBodyDataSource
Factory method that can be overridden to provide a different implementation.- Returns:
- DataSource A new MessageBodyDataSource constructed from the current body and type.
-