Class MailMessage
java.lang.Object
de.muehlencord.shared.network.mail.MailMessage
A mail message
- Author:
- Joern Muehlencord (joern@muehlencord.de)
-
Constructor Summary
ConstructorsConstructorDescriptionMailMessage(String subj, String contentString) creates a new instance of a MailMessageMailMessage(String subj, String contentString, String id) creates a new instance of MaiLmessage -
Method Summary
Modifier and TypeMethodDescriptionvoidaddBccReceiver(String rcv) voidaddBccReceiver(javax.mail.Address[] addresses) adds the give list of addresses to the bcc receiver listvoidaddCcReceiver(String rcv) voidaddCcReceiver(javax.mail.Address[] addresses) adds the give list of addresses to the cc receiver listvoidaddReceiver(String rcv) voidaddReceiver(List<String> rcvList) adds the given receiver to the list of receiversvoidaddReceiver(javax.mail.Address[] addresses) adds the give list of addresses to the receiver listreturns the html content stringintgetSize()booleanvoidsetContent(String c, boolean isHtmlContent) sets the content string of the messagevoidsets the html content of the messagevoidsets the sender addressvoidsetSender(javax.mail.Address[] sender) sets the sender addressvoidsetSentDate(Date date) voidsetSize(int messageSize) sets the size of the message in bytes
-
Constructor Details
-
MailMessage
creates a new instance of a MailMessage- Parameters:
subj- the subject of the messagecontentString- the content of the message
-
MailMessage
creates a new instance of MaiLmessage- Parameters:
subj- the subject of the messagecontentString- the content of the messageid- the message id the message was sent with
-
-
Method Details
-
getSubject
- Returns:
- the subject
-
getContent
- Returns:
- the content
-
setContent
sets the content string of the message- Parameters:
c- the content to setisHtmlContent- if set to true, given content is treated as html content
-
setHtmlContent
sets the html content of the message- Parameters:
c- the content to set (html string)
-
getHtmlContent
returns the html content string- Returns:
- the html content string
-
isHtmlMessage
public boolean isHtmlMessage()- Returns:
- the isHtmlMessage
-
getMessageId
- Returns:
- the messageId
-
setSize
public void setSize(int messageSize) sets the size of the message in bytes- Parameters:
messageSize- the size of the message in bytes
-
getSize
public int getSize()- Returns:
- the message size in bytes
-
getSentDate
- Returns:
- the sentDate
-
setSentDate
- Parameters:
date- the sentDate to set
-
getSender
- Returns:
- the sender
-
setSender
sets the sender address- Parameters:
sender- the sender to set
-
setSender
public void setSender(javax.mail.Address[] sender) sets the sender address- Parameters:
sender- the sender to set
-
getReceiver
- Returns:
- the receiver
-
addReceiver
- Parameters:
rcv- the receiver to set
-
addReceiver
adds the given receiver to the list of receivers- Parameters:
rcvList- the receiver to add
-
addReceiver
public void addReceiver(javax.mail.Address[] addresses) adds the give list of addresses to the receiver list- Parameters:
addresses- the addresses to add
-
getCcReceiver
- Returns:
- the ccReceiver
-
addCcReceiver
- Parameters:
rcv- the ccReceiver to set
-
addCcReceiver
public void addCcReceiver(javax.mail.Address[] addresses) adds the give list of addresses to the cc receiver list- Parameters:
addresses- the addresses to add
-
getBccReceiver
- Returns:
- the bccReceiver
-
addBccReceiver
- Parameters:
rcv- the bccReceiver to set
-
addBccReceiver
public void addBccReceiver(javax.mail.Address[] addresses) adds the give list of addresses to the bcc receiver list- Parameters:
addresses- the addresses to add
-