Interface IMailMessage

All Known Implementing Classes:
HtmlMailMessage, MailMessage, TextMailMessage

public interface IMailMessage
This interface describes the content of an email message. Note: this interface does not (yet) support attachments.
Since:
6.4
Author:
Jon van Leuven
  • Method Details

    • getFrom

      IMailAddress getFrom()
      This method returns the sender's address.
      Returns:
      The email addres of the sender, may not be null.
    • getCc

      IMailAddress[] getCc()
      This method returns the recipient addresses that receive a cc (carbon copy) message.
      Returns:
      An array of email address, if no cc specified it must return IMailAddress[0].
    • getBcc

      IMailAddress[] getBcc()
      This method returns the recipient addresses that receive a bcc (blind carbon copy) message.
      Returns:
      An array of email address, if no bcc specified it must return IMailAddress[0].
    • getTo

      IMailAddress[] getTo()
      This method returns the recipient addresses.
      Returns:
      An array of email address, if no recipient specified it must return IMailAddress[0].
    • getAttachments

      IMailMessageAttachment[] getAttachments()
      This method returns the mail attachments.
      Returns:
      An array of mail attachments, never null, can be empty.
    • getSubject

      String getSubject()
      This method returns the subject of the message.
      Returns:
      The subject of the email message, may be null.
    • getBody

      String getBody()
      This method returns the body of the message.
      Returns:
      The body of the email message, may be null.
    • getContentType

      String getContentType()
      This method returns the Content-Type header for the specific type of message.
      Returns:
      the Content-Type header for the specific type of message.