| org.springframework.mail.javamail.MimeMessagePreparator |
Callback interface for the preparation of JavaMail MIME messages.
The corresponding send methods of JavaMailSender
will take care of the actual creation of a MimeMessage instance,
and of proper exception conversion.
It is often convenient to use a MimeMessageHelper for populating
the passed-in MimeMessage, in particular when working with attachments or
special character encodings.
See MimeMessageHelper's javadoc for an example.
MimeMessageHelper| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Prepare the given new MimeMessage instance.
| |||||||||||
Prepare the given new MimeMessage instance.
| mimeMessage | the message to prepare |
|---|
| passing any exceptions thrown by MimeMessage methods through for automatic conversion to the MailException hierarchy | |
| IOException | passing any exceptions thrown by MimeMessage methods through for automatic conversion to the MailException hierarchy |
| Exception | if mail preparation failed, for example when a Velocity template cannot be rendered for the mail text |