Class MailConfiguration

java.lang.Object
com.saperion.common.mail.MailConfiguration
All Implemented Interfaces:
Cloneable

public class MailConfiguration extends Object implements Cloneable

Configuration-object for the Mailing class.

This implementation is not synchronized. If used by different threads concurrently, external synchronization is necessary.

Author:
sts
See Also:
  • Constructor Details

    • MailConfiguration

      public MailConfiguration()
  • Method Details

    • isDebugEnabled

      public boolean isDebugEnabled()
      Indicates if SMTP debug should be enabled.
      Returns:
      true if SMTP debug should be enabled, false otherwise.
    • setDebugEnabled

      public MailConfiguration setDebugEnabled(boolean isDebugEnabled)
      Sets if SMTP debug enabled.
      Parameters:
      isDebugEnabled - enabled (true) or disabled (false).
      Returns:
      this instance.
    • getSmtpServer

      public String getSmtpServer()
      Returns the SMTP Server URL or IP-address.
      Returns:
      the SMTP Server URL or IP-address
    • setSmtpServer

      public MailConfiguration setSmtpServer(String smtpServer)
      Sets the SMTP server URL or IP-address.
      Parameters:
      smtpServer - URL or IP-address
      Returns:
      this instance.
    • getSmtpUser

      public String getSmtpUser()
      Returns the SMTP user name. May be null or empty, if no SMTP authentication should be used.
      Returns:
      the SMTP user name
    • setSmtpUser

      public MailConfiguration setSmtpUser(String smtpUser)
      Sets the SMTP user name of SMTP authentication should be used.
      Parameters:
      smtpUser - SMTP user name.
      Returns:
      this instance.
    • getSmtpPassword

      public String getSmtpPassword()
      Returns the SMTP password. May be null or empty, if no SMTP authentication should be used.
      Returns:
      the SMTP password. May be null or empty, if no SMTP authentication should be used.
    • setSmtpPassword

      public MailConfiguration setSmtpPassword(String smtpPassword)
      Sets the SMTP password for SMTP authentication.
      Parameters:
      smtpPassword - the password.
      Returns:
      this instance.
    • getSmtpPort

      public int getSmtpPort()
      Returns the port of the SMTP server.
      Returns:
      the port of the SMTP server
    • setSmtpPort

      public MailConfiguration setSmtpPort(int smtpPort)
      Sets the port of the SMTP server.
      Parameters:
      smtpPort - the port.
      Returns:
      this instance.
    • isSslEnabled

      public boolean isSslEnabled()
      Indicates if SSL should be used.
      Returns:
      true if SSL should be used, false otherwise.
    • setSslEnabled

      public MailConfiguration setSslEnabled(boolean isSslEnabled)
      Sets if SSL should be used.
      Parameters:
      isSslEnabled - true, SSL should be used, false otherwise.
      Returns:
      this instance.
    • clone

      public MailConfiguration clone()
      Overrides:
      clone in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object