1 | <?php |
||
9 | class EmailDestination extends Destination |
||
10 | { |
||
11 | /** |
||
12 | * @var string[] |
||
13 | */ |
||
14 | protected $to; |
||
15 | |||
16 | /** |
||
17 | * @var string[] |
||
18 | */ |
||
19 | protected $cc; |
||
20 | |||
21 | /** |
||
22 | * @var string[] |
||
23 | */ |
||
24 | protected $bcc; |
||
25 | |||
26 | /** |
||
27 | * @var SmtpConfiguration |
||
28 | */ |
||
29 | protected $smtpConfiguration; |
||
30 | |||
31 | /** |
||
32 | * @param array $to |
||
33 | * @param array $cc |
||
34 | * @param array $bcc |
||
35 | * @param SmtpConfiguration|null $smtpConfiguration |
||
36 | */ |
||
37 | 28 | public function __construct( |
|
48 | |||
49 | /** |
||
50 | * @return EmailAddress[] |
||
51 | */ |
||
52 | 3 | public function to(): array |
|
56 | |||
57 | /** |
||
58 | * @return EmailAddress[] |
||
59 | */ |
||
60 | 3 | public function cc(): array |
|
64 | |||
65 | /** |
||
66 | * @return EmailAddress[] |
||
67 | */ |
||
68 | 3 | public function bcc(): array |
|
72 | |||
73 | /** |
||
74 | * @return null|SmtpConfiguration |
||
75 | */ |
||
76 | 3 | public function smtpConfiguration(): ?SmtpConfiguration |
|
80 | |||
81 | /** |
||
82 | * @param EmailAddress[] $emailAddresses |
||
83 | * @return string[] |
||
84 | */ |
||
85 | 28 | protected static function toStringArray(array $emailAddresses) |
|
91 | |||
92 | /** |
||
93 | * @param string[] $emailAddresses |
||
94 | * @return EmailAddress[] |
||
95 | */ |
||
96 | 7 | protected static function toObjectArray(array $emailAddresses): array |
|
102 | |||
103 | /** |
||
104 | * @return string |
||
105 | */ |
||
106 | 7 | public function jsonRepresentation(): string |
|
122 | |||
123 | /** |
||
124 | * {@inheritdoc} |
||
125 | */ |
||
126 | 5 | public static function fromJsonRepresentation(string $jsonRepresentation): Destination |
|
144 | } |
||
145 |