1 | <?php |
||
8 | class EmailDestination implements Destination |
||
9 | { |
||
10 | /** |
||
11 | * @var string[] |
||
12 | */ |
||
13 | private $to; |
||
14 | |||
15 | /** |
||
16 | * @var string[] |
||
17 | */ |
||
18 | private $cc; |
||
19 | |||
20 | /** |
||
21 | * @var string[] |
||
22 | */ |
||
23 | private $bcc; |
||
24 | |||
25 | /** |
||
26 | * @param EmailAddress[] $to |
||
27 | * @param EmailAddress[] $cc |
||
28 | * @param EmailAddress[] $bcc |
||
29 | */ |
||
30 | 7 | public function __construct(array $to, array $cc = [], array $bcc = []) |
|
36 | |||
37 | /** |
||
38 | * @return EmailAddress[] |
||
39 | */ |
||
40 | 2 | public function to(): array |
|
41 | { |
||
42 | 2 | return $this->toObjectArray($this->to); |
|
43 | } |
||
44 | |||
45 | /** |
||
46 | * @return EmailAddress[] |
||
47 | */ |
||
48 | 2 | public function cc(): array |
|
49 | { |
||
50 | 2 | return $this->toObjectArray($this->cc); |
|
51 | } |
||
52 | |||
53 | /** |
||
54 | * @return EmailAddress[] |
||
55 | */ |
||
56 | 2 | public function bcc(): array |
|
57 | { |
||
58 | 2 | return $this->toObjectArray($this->bcc); |
|
59 | } |
||
60 | |||
61 | /** |
||
62 | * @param EmailAddress[] $emailAddresses |
||
63 | * @return string[[ |
||
|
|||
64 | */ |
||
65 | 7 | private function toStringArray(array $emailAddresses) |
|
71 | |||
72 | /** |
||
73 | * @param string[] $emailAddresses |
||
74 | * @return EmailAddress[] |
||
75 | */ |
||
76 | 2 | private function toObjectArray(array $emailAddresses): array |
|
82 | |||
83 | /** |
||
84 | * {@inheritdoc} |
||
85 | */ |
||
86 | 3 | public function destinationType(): string |
|
90 | } |
||
91 |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.