接口 MailSender

所有已知子接口:
JavaMailSender
所有已知实现类:
JavaMailSenderImpl

public interface MailSender
This interface defines a strategy for sending simple mails. Can be implemented for a variety of mailing systems due to the simple requirements. For richer functionality like MIME messages, consider JavaMailSender.

Allows for easy testing of clients, as it does not depend on JavaMail's infrastructure classes: no mocking of JavaMail Session or Transport necessary.

从以下版本开始:
4.0
作者:
Dmitriy Kopylenko, Juergen Hoeller, Harry Yang
另请参阅:
  • 方法概要

    修饰符和类型
    方法
    说明
    void
    send(SimpleMailMessage simpleMessage)
    Send the given simple mail message.
    void
    send(SimpleMailMessage... simpleMessages)
    Send the given array of simple mail messages in batch.