All Downloads are FREE. Search and download functionalities are using the official Maven repository.

woko.mail.MailServiceBase Maven / Gradle / Ivy

There is a newer version: 2.4-beta7
Show newest version
package woko.mail;

import java.util.HashMap;
import java.util.Map;

public abstract class MailServiceBase implements MailService {

    private final String appUrl;
    private final String fromEmailAddress;
    private final Map templates;

    public MailServiceBase(String appUrl, String fromEmailAddress, Map templates) {
        this.appUrl = appUrl;
        this.fromEmailAddress = fromEmailAddress;
        this.templates = new HashMap(templates);
    }

    @Override
    public MailTemplate getMailTemplate(String name) {
        return templates.get(name);
    }

    @Override
    public String getAppUrl() {
        return appUrl;
    }

    @Override
    public String getFromEmailAddress() {
        return fromEmailAddress;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy