1 | <?php |
||
11 | class EmailAlerter implements AlerterInterface |
||
12 | { |
||
13 | protected $mailer; |
||
14 | protected $host; |
||
15 | protected $recipient; |
||
16 | |||
17 | /** |
||
18 | * Set the swift mailer |
||
19 | * |
||
20 | * @param Swift_Mailer $mailer |
||
21 | */ |
||
22 | 9 | public function setMailer(Swift_Mailer $mailer) |
|
26 | |||
27 | /** |
||
28 | * Set host name used to build 'From' email |
||
29 | * |
||
30 | * @param string $host |
||
31 | */ |
||
32 | 9 | public function setHost($host) |
|
36 | |||
37 | /** |
||
38 | * Set the emails recipient |
||
39 | * |
||
40 | * @param string $recipient |
||
41 | */ |
||
42 | public function setRecipient($recipient) |
||
46 | |||
47 | /** |
||
48 | * {@inheritdoc} |
||
49 | */ |
||
50 | 9 | public function alert(Alert $alert) |
|
88 | } |
||
89 |