Upgraded drupal core with security updates
[yaffs-website] / web / core / modules / contact / src / MailHandlerInterface.php
1 <?php
2
3 namespace Drupal\contact;
4
5 use Drupal\Core\Session\AccountInterface;
6
7 /**
8  * Provides an interface for assembly and dispatch of contact mail messages.
9  */
10 interface MailHandlerInterface {
11
12   /**
13    * Sends mail messages as appropriate for a given Message form submission.
14    *
15    * Can potentially send up to three messages as follows:
16    * - To the configured recipient;
17    * - Auto-reply to the sender; and
18    * - Carbon copy to the sender.
19    *
20    * @param \Drupal\contact\MessageInterface $message
21    *   Submitted message entity.
22    * @param \Drupal\Core\Session\AccountInterface $sender
23    *   User that submitted the message entity form.
24    *
25    * @throws \Drupal\contact\MailHandlerException
26    *   When unable to determine message recipient.
27    */
28   public function sendMailMessages(MessageInterface $message, AccountInterface $sender);
29
30 }