1 | <?php |
||
12 | class SendEmailAfterExecution implements CheckInterface |
||
13 | { |
||
14 | /** @var Mailer */ |
||
15 | private $mailer; |
||
16 | |||
17 | /** @var EmailConfig */ |
||
18 | private $config; |
||
19 | |||
20 | /** @var View */ |
||
21 | private $view; |
||
22 | |||
23 | /** @var Connection */ |
||
24 | private $connection; |
||
25 | |||
26 | |||
27 | |||
28 | public function __construct(Mailer $mailer, EmailConfig $config, View $view, Connection $connection) |
||
35 | |||
36 | |||
37 | |||
38 | public function execute(Candidate $candidate): bool |
||
49 | |||
50 | |||
51 | |||
52 | /** |
||
53 | * @inheritDoc |
||
54 | */ |
||
55 | public function getErrorCode(): string |
||
59 | |||
60 | |||
61 | |||
62 | /** |
||
63 | * @inheritDoc |
||
64 | */ |
||
65 | public function getLastErrorMessage(): string |
||
69 | |||
70 | |||
71 | |||
72 | private function composeMessage(Candidate $candidate): Swift_Message |
||
90 | } |
||
91 |