Package com.google.code.lightssh.common.mail

Examples of com.google.code.lightssh.common.mail.MailAddress


   * 发邮件
   */
  public void send(EmailContent ec ){
    ConnectionConfig config = getEmailConnectionConfig();
   
    MailAddress mailAddress = new MailAddress( );
    mailAddress.setFrom(config.getUsername(),config.getUsername());
   
    for( String item:ec.getAddressees())
      mailAddress.addTo(item, "");
   
    if( !StringUtils.isEmpty(ec.getCc()) ){
      for( String item:ec.getCcs())
        mailAddress.addCc(item, "");
    }
   
    boolean success = false;
    try{
      mailSender.sendHtml(config,mailAddress
View Full Code Here


   */
  public void forgotUsername(String title, String email ){
    ConnectionConfig config = getEmailConnectionConfig();
    Address to = new Address(email,title);
    Address from = new Address(config.getUsername(),config.getUsername());
    MailAddress mailAddress = new MailAddress( to,from );
   
    StringBuffer content = new StringBuffer();
    content.append("您在系统的登录帐号为:" + title);
   
    mailSender.send(config,mailAddress
View Full Code Here

      return ;
   
    ConnectionConfig config = getEmailConnectionConfig();
    Address to = new Address(account.getEmail(),account.getLoginName());
    Address from = new Address(config.getUsername(),config.getUsername());
    MailAddress mailAddress = new MailAddress( to,from );
   
    StringBuffer content = new StringBuffer();
    content.append("<html>");
    //content.append("<img src=\"http://www.gstatic.com/codesite/ph/images/defaultlogo.png\"></br>");
    content.append("\n要重设您系统帐户 "+account.getLoginName()+" 的密码,请点击以下链接:" );
View Full Code Here

TOP

Related Classes of com.google.code.lightssh.common.mail.MailAddress

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.