Version 4.10.0

hirondelle.web4j.webmaster
Class EmailerImpl

Object
  extended by hirondelle.web4j.webmaster.EmailerImpl
All Implemented Interfaces:
Emailer

public final class EmailerImpl
extends Object
implements Emailer

Default implementation of Emailer.

Uses these init-param settings in web.xml:

Example web.xml settings, using a Gmail account:

    <init-param>
      <param-name>Webmaster</param-name>
      <param-value>myaccount@gmail.com</param-value> 
    </init-param>

    <init-param>
      <param-name>MailServerConfig</param-name>
      <param-value>
        mail.smtp.host=smtp.gmail.com       
        mail.smtp.auth=true
        mail.smtp.port=465
        mail.smtp.socketFactory.port=465
        mail.smtp.socketFactory.class=javax.net.ssl.SSLSocketFactory
      </param-value> 
    </init-param>

    <init-param>
      <param-name>MailServerCredentials</param-name>
      <param-value>myaccount@gmail.com|mypassword</param-value> 
    </init-param>
  


Constructor Summary
EmailerImpl()
           
 
Method Summary
 void sendFromWebmaster(List<String> aToAddresses, String aSubject, String aBody)
          Send an email from the webmaster to a list of receivers.
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EmailerImpl

public EmailerImpl()
Method Detail

sendFromWebmaster

public void sendFromWebmaster(List<String> aToAddresses,
                              String aSubject,
                              String aBody)
                       throws AppException
Description copied from interface: Emailer
Send an email from the webmaster to a list of receivers.

Specified by:
sendFromWebmaster in interface Emailer
Parameters:
aToAddresses - contains email addresses of the receivers, as a List of Strings that satisfy WebUtil.isValidEmailAddress(String)
aSubject - satisfies Util.textHasContent(java.lang.String)
aBody - satisfies Util.textHasContent(java.lang.String)
Throws:
AppException

Version 4.10.0

Copyright Hirondelle Systems. Published October 19, 2013 - User Guide - All Docs.