Package org.fao.geonet.util

Examples of org.fao.geonet.util.MailSender


       

        if (!emailNotes) {
            context.info("Would send email \nTo: " + sendTo + "\nSubject: " + subject + "\n Message:\n" + message);
        } else {
            MailSender sender = new MailSender(context);
            sender.sendWithReplyTo(host, Integer.parseInt(port), username, password, useSSL, from, fromDescr,
                sendTo, null, replyTo, replyToDescr, subject, message);
        }
    }
View Full Code Here


            GeonetContext geonetContext = (GeonetContext) serviceContext.getHandlerContext(Geonet.CONTEXT_NAME);
            SettingManager settingManager = geonetContext.getBean(SettingManager.class);
            String host = settingManager.getValue("system/feedback/mailServer/host");
            String port = settingManager.getValue("system/feedback/mailServer/port");
            String to = responseHandler.substring(Protocol.EMAIL.toString().length());
            MailSender sender = new MailSender(serviceContext);
            sender.send(host, Integer.parseInt(port),
                    settingManager.getValue("system/feedback/mailServer/username"),
                    settingManager.getValue("system/feedback/mailServer/password"),
                    settingManager.getValueAsBool("system/feedback/mailServer/ssl"),
                    "noreply@geonetwork.org",
                    "GeoNetwork CSW Server", to, null, "Asynchronous CSW Harvest results delivery", harvestResponse);
View Full Code Here

    String subject  = Util.getParam(params, Params.SUBJECT, "New feedback")// TODO : i18n

    String host = sm.getValue("system/feedback/mailServer/host");
    String to   = sm.getValue("system/feedback/email");

    MailSender sender = new MailSender(context);
    sender.send(host,
            sm.getValueAsInt("system/feedback/mailServer/port"),
            sm.getValue("system/feedback/mailServer/username"),
            sm.getValue("system/feedback/mailServer/password"),
            sm.getValueAsBool("system/feedback/mailServer/ssl"),
            email, name +" ("+org+")", to, null, subject, comments);
View Full Code Here

              + " has been downloaded from address " + context.getIpAddress()
              + " by user " + username
              + ".";

            try {
              MailSender sender = new MailSender(context);
              sender.send(host, Integer.parseInt(port),
                      sm.getValue("system/feedback/mailServer/username"),
                      sm.getValue("system/feedback/mailServer/password"),
                      sm.getValueAsBool("system/feedback/mailServer/ssl"),
                      from, fromDescr, email, null, subject, message);
            } catch (Exception e) {
View Full Code Here

              + " belonging metadata "+ id
              + " has beed downloaded from address " + context.getIpAddress() + ".";

            try
            {
              MailSender sender = new MailSender(context);
              sender.send(host, Integer.parseInt(port),
                      sm.getValue("system/feedback/mailServer/username"),
                      sm.getValue("system/feedback/mailServer/password"),
                      sm.getValueAsBool("system/feedback/mailServer/ssl"),
                      from, fromDescr, email, null, subject, message);
            }
View Full Code Here

TOP

Related Classes of org.fao.geonet.util.MailSender

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.