1 | <?php |
||
8 | class SmscRuChannel |
||
9 | { |
||
10 | /** @var SmscRuApi */ |
||
11 | protected $smsc; |
||
12 | |||
13 | 4 | public function __construct(SmscRuApi $smsc) |
|
17 | |||
18 | /** |
||
19 | * Send the given notification. |
||
20 | * |
||
21 | * @param mixed $notifiable |
||
22 | * @param Notification $notification |
||
23 | * |
||
24 | * @throws CouldNotSendNotification |
||
25 | * |
||
26 | * @return array|null |
||
27 | */ |
||
28 | 4 | public function send($notifiable, Notification $notification): ?array |
|
42 | |||
43 | /** |
||
44 | * Gets a list of phones from the given notifiable. |
||
45 | * |
||
46 | * @param mixed $notifiable |
||
47 | * @param Notification $notification |
||
48 | * |
||
49 | * @return string[] |
||
50 | */ |
||
51 | 4 | protected function getRecipients($notifiable, Notification $notification): array |
|
61 | |||
62 | 3 | protected function sendMessage($recipients, SmscRuMessage $message) |
|
80 | } |
||
81 |