Class MailImpl
java.lang.Object
ch.tocco.nice2.messaging.mail.spi.AbstractBaseMail
ch.tocco.nice2.messaging.mail.spi.AbstractOutgoingMail
ch.tocco.nice2.messaging.mail.impl.MailImpl
-
Nested Class Summary
Nested classes/interfaces inherited from interface ch.tocco.nice2.messaging.mail.api.Mail
Mail.MailListener -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final MessageReaderprotected final jakarta.mail.SessionFields inherited from class ch.tocco.nice2.messaging.mail.spi.AbstractOutgoingMail
attributes, charset, contactCategory, encodeFileNames, expiryDate, listeners, mailArchive, mailSendThrottle, nice2Template, persistenceService, preventFromArchive, processor, recipientEntity, relatedEntity, sender, singleCopyMail, sourceEntities, sourceEntity, taskUuid, templateAttributes, templateEngine, templateEntityFields inherited from class ch.tocco.nice2.messaging.mail.spi.AbstractBaseMail
attachments, bcc, cc, from, html, log, replyTo, subject, text, toFields inherited from interface ch.tocco.nice2.messaging.mail.api.BaseMail
NO_SUBJECT -
Constructor Summary
ConstructorsConstructorDescriptionMailImpl(String subject, jakarta.mail.Session session, MessageProcessor processor, PersistenceService persistenceService, org.slf4j.Logger log, TemplateEngineFactory templateEngineFactory, MailArchive mailArchive, MailSendThrottle mailSendThrottle, Boolean encodeFileNames, MessageReader messageReader) -
Method Summary
Modifier and TypeMethodDescriptionclone()protected MailArchive.MailArchiveEntrydoSend()getBody()Methods inherited from class ch.tocco.nice2.messaging.mail.spi.AbstractOutgoingMail
addBcc, addBcc, addBcc, addCc, addCc, addCc, addMailListener, addSourceEntity, addTo, addTo, addTo, checkRecipientAndContent, getAttributes, getCharset, getContactCategory, getExpiryDate, getRecipientEntity, getRelatedEntity, getSender, getSourceEntity, getTaskUuid, getTemplateAttribute, getTemplateAttributes, getTemplateEntity, hasNoRecipients, isSingleCopyMail, preventFromArchive, processTemplate, processTemplate, processTemplateWithHtmlEscape, removeMailListener, send, setCharset, setContactCategory, setExpiryDate, setFrom, setRecipientEntity, setRelatedEntity, setSender, setSingleCopyMail, setSourceEntity, setTaskUuid, setTemplateAttribute, setTemplateEntity, setTemplateEntityData, setTemplateEntityListDataMethods inherited from class ch.tocco.nice2.messaging.mail.spi.AbstractBaseMail
addAttachment, addBcc, addBcc, addCc, addCc, addReplyTo, addReplyTo, addReplyTo, addTo, addTo, addTo, clearAttachments, clearBcc, clearCc, clearReplyTo, clearTo, containsAttachment, createAttachment, createAttachment, createAttachment, getAttachments, getBcc, getCc, getFrom, getHtml, getReplyTo, getSubject, getText, getTo, isBodyEmpty, mergeWithExistingHtml, removeAttachment, setBcc, setCc, setFrom, setHtml, setReplyTo, setSubject, setText, setTo, toStringMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface ch.tocco.nice2.messaging.mail.api.BaseMail
addAttachment, addBcc, addBcc, addCc, addCc, addReplyTo, addReplyTo, addReplyTo, addTo, addTo, addTo, clearAttachments, clearBcc, clearCc, clearReplyTo, clearTo, createAttachment, createAttachment, createAttachment, getAttachments, getBcc, getCc, getFrom, getHtml, getReplyTo, getSubject, getText, getTo, isBodyEmpty, setFrom, setHtml, setSubject, setTextMethods inherited from interface ch.tocco.nice2.messaging.mail.api.Mail
containsAttachment, removeAttachment
-
Field Details
-
session
protected final jakarta.mail.Session session -
messageReader
-
-
Constructor Details
-
MailImpl
public MailImpl(String subject, jakarta.mail.Session session, MessageProcessor processor, PersistenceService persistenceService, org.slf4j.Logger log, TemplateEngineFactory templateEngineFactory, MailArchive mailArchive, MailSendThrottle mailSendThrottle, Boolean encodeFileNames, MessageReader messageReader)
-
-
Method Details
-
getBody
- Throws:
MailException
-
getMimeMessageHeaders
public Map<String,Iterable<String>> getMimeMessageHeaders() throws MailException, jakarta.mail.MessagingException- Throws:
MailExceptionjakarta.mail.MessagingException
-
getMimeMessageFrom
- Throws:
jakarta.mail.MessagingExceptionMailException
-
doSend
- Specified by:
doSendin classAbstractOutgoingMail- Throws:
MailException
-
clone
- Specified by:
clonein interfaceMail- Overrides:
clonein classAbstractOutgoingMail- Throws:
CloneNotSupportedException
-