Package com.axelor.mail.db
Class MailMessage
java.lang.Object
com.axelor.db.Model
com.axelor.auth.db.AuditableModel
com.axelor.mail.db.MailMessage
The model to store different kind of messages like system notifications,
comments, email messages etc.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Add the givenMailFlags
item to theflags
collection.void
addRecipient
(MailAddress item) Add the givenMailAddress
item to therecipients
collection.void
addReply
(MailMessage item) Add the givenMailMessage
item to thereplies
collection.void
Clear theflags
collection.void
Clear therecipients
collection.void
Clear thereplies
collection.boolean
getBody()
getFlags()
getFrom()
getId()
Unique message identifiergetRoot()
getType()
int
hashCode()
void
removeFlag
(MailFlags item) Remove the givenMailFlags
item from theflags
collection.void
removeRecipient
(MailAddress item) Remove the givenMailAddress
item from therecipients
collection.void
removeReply
(MailMessage item) Remove the givenMailMessage
item from thereplies
collection.void
void
void
void
setFrom
(MailAddress from) void
void
setMessageId
(String messageId) void
setParent
(MailMessage parent) void
setRecipients
(Set<MailAddress> recipients) void
setRelatedId
(Long relatedId) void
setRelatedModel
(String relatedModel) void
setRelatedName
(String relatedName) void
setReplies
(List<MailMessage> replies) void
setRoot
(MailMessage root) void
setSubject
(String subject) void
setSummary
(String summary) void
toString()
Methods inherited from class com.axelor.auth.db.AuditableModel
getCreatedBy, getCreatedOn, getUpdatedBy, getUpdatedOn
Methods inherited from class com.axelor.db.Model
getArchived, getCid, getVersion, isSelected, setArchived, setCid, setSelected, setVersion
-
Constructor Details
-
MailMessage
public MailMessage()
-
-
Method Details
-
getId
-
setId
-
getType
-
setType
-
getAuthor
-
setAuthor
-
getFrom
-
setFrom
-
getRecipients
-
setRecipients
-
addRecipient
Add the givenMailAddress
item to therecipients
collection.- Parameters:
item
- the item to add
-
removeRecipient
Remove the givenMailAddress
item from therecipients
collection.- Parameters:
item
- the item to remove
-
clearRecipients
public void clearRecipients()Clear therecipients
collection. -
getSubject
-
setSubject
-
getBody
-
setBody
-
getSummary
-
setSummary
-
getMessageId
Unique message identifier- Returns:
- the property value
-
setMessageId
-
getRelatedId
-
setRelatedId
-
getRelatedModel
-
setRelatedModel
-
getRelatedName
-
setRelatedName
-
getRoot
-
setRoot
-
getParent
-
setParent
-
getReplies
-
setReplies
-
addReply
Add the givenMailMessage
item to thereplies
collection.It sets
item.parent = this
to ensure the proper relationship.- Parameters:
item
- the item to add
-
removeReply
Remove the givenMailMessage
item from thereplies
collection.- Parameters:
item
- the item to remove
-
clearReplies
public void clearReplies()Clear thereplies
collection. -
getFlags
-
setFlags
-
addFlag
Add the givenMailFlags
item to theflags
collection.It sets
item.message = this
to ensure the proper relationship.- Parameters:
item
- the item to add
-
removeFlag
Remove the givenMailFlags
item from theflags
collection.- Parameters:
item
- the item to remove
-
clearFlags
public void clearFlags()Clear theflags
collection. -
equals
-
hashCode
public int hashCode() -
toString
-