| 1 | <?php |
||
| 10 | class BroadcastChannel |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * The event dispatcher. |
||
| 14 | * |
||
| 15 | * @var \Illuminate\Contracts\Events\Dispatcher |
||
| 16 | */ |
||
| 17 | protected $events; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * Create a new database channel. |
||
| 21 | * |
||
| 22 | * @param \Illuminate\Contracts\Events\Dispatcher $events |
||
| 23 | * @return void |
||
|
|
|||
| 24 | */ |
||
| 25 | 1 | public function __construct(Dispatcher $events) |
|
| 29 | |||
| 30 | /** |
||
| 31 | * Send the given notification. |
||
| 32 | * |
||
| 33 | * @param mixed $notifiable |
||
| 34 | * @param \Illuminate\Notifications\Notification $notification |
||
| 35 | * @return void |
||
| 36 | */ |
||
| 37 | 1 | public function send($notifiable, Notification $notification) |
|
| 43 | |||
| 44 | /** |
||
| 45 | * Get the data for the notification. |
||
| 46 | * |
||
| 47 | * @param mixed $notifiable |
||
| 48 | * @param \Illuminate\Notifications\Notification $notification |
||
| 49 | * @return array |
||
| 50 | * |
||
| 51 | * @throws \RuntimeException |
||
| 52 | */ |
||
| 53 | 1 | protected function getData($notifiable, Notification $notification) |
|
| 63 | } |
||
| 64 |
Adding a
@returnannotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.