Package org.pentaho.platform.api.email
Interface IEmailService
-
public interface IEmailService
The Email Service used in the Pentaho Platform
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description IEmailConfiguration
getEmailConfig()
Retrieves the current email configurationboolean
isValid()
void
sendEmail(javax.mail.Session session, javax.mail.internet.MimeMessage msg)
Sends a mail using SMTP or Graph API depending on ParamsString
sendEmailTest(IEmailConfiguration emailConfig)
Generates a test email via the specficied email configurationvoid
setEmailConfig(IEmailConfiguration emailConfiguration)
Saves the email configuration
-
-
-
Method Detail
-
setEmailConfig
void setEmailConfig(IEmailConfiguration emailConfiguration)
Saves the email configuration- Parameters:
emailConfiguration
- the email configuration to save as the current email configuration
-
getEmailConfig
IEmailConfiguration getEmailConfig()
Retrieves the current email configuration
-
sendEmailTest
String sendEmailTest(IEmailConfiguration emailConfig)
Generates a test email via the specficied email configuration- Parameters:
emailConfig
- the email configuration to use for sending the testing email
-
isValid
boolean isValid()
-
sendEmail
void sendEmail(javax.mail.Session session, javax.mail.internet.MimeMessage msg) throws EmailServiceException
Sends a mail using SMTP or Graph API depending on Params- Parameters:
session
- the java mail session required for SMTP connectionsmsg
- the message object in form of MimeMessage. Sent as object for SMTP and as Base64 string in Graph API calls- Throws:
EmailServiceException
-
-