Package com.ibm.sbt.services.client.email

Examples of com.ibm.sbt.services.client.email.MimeEmail


    private JsonObject send(List<JsonObject> emails) {
        MimeEmailFactory emailFactory = DefaultMimeEmailFactory.getInstance();
        List<JsonObject> successful = new ArrayList<JsonObject>();
        List<JsonObject> error = new ArrayList<JsonObject>();
        for(JsonObject json : emails) {
            MimeEmail email;
            try {
                email = emailFactory.createMimeEmail(json);
                if(email != null) {
                    email.send();
                    successful.add(json);
                } else {
                    error.add(createErrorResponse(json, "Email could not be created from JSON."));
                }
            } catch (MimeEmailException e) {
View Full Code Here

TOP

Related Classes of com.ibm.sbt.services.client.email.MimeEmail

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.