Code Coverage |
||||||||||
Classes and Traits |
Functions and Methods |
Lines |
||||||||
| Total | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
CRAP | |
100.00% |
3 / 3 |
| BaseChannel | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |
100.00% |
3 / 3 |
| __construct | |
100.00% |
1 / 1 |
1 | |
100.00% |
3 / 3 |
|||
| send | n/a |
0 / 0 |
0 | n/a |
0 / 0 |
|||||
| 1 | <?php |
| 2 | |
| 3 | namespace AGILEDROP\LaravelTelnyx\Channels; |
| 4 | |
| 5 | use Illuminate\Notifications\Notification; |
| 6 | |
| 7 | abstract class BaseChannel |
| 8 | { |
| 9 | |
| 10 | /** |
| 11 | * The Telnyx profile ID |
| 12 | * |
| 13 | * @var string |
| 14 | */ |
| 15 | protected $profileId; |
| 16 | |
| 17 | /** |
| 18 | * The phone number notifications should be sent from. |
| 19 | * |
| 20 | * @var string |
| 21 | */ |
| 22 | protected $from; |
| 23 | |
| 24 | /** |
| 25 | * Create a new Telnyx channel instance. |
| 26 | * |
| 27 | * @param $profileId |
| 28 | * @param string $from |
| 29 | * |
| 30 | */ |
| 31 | public function __construct($profileId, $from) |
| 32 | { |
| 33 | $this->profileId = $profileId; |
| 34 | $this->from = $from; |
| 35 | } |
| 36 | |
| 37 | /** |
| 38 | * Send the given notification. |
| 39 | * |
| 40 | * @param mixed $notifiable |
| 41 | * @param \Illuminate\Notifications\Notification $notification |
| 42 | * |
| 43 | * @return \Telnyx\ApiResource|null |
| 44 | */ |
| 45 | abstract public function send($notifiable, Notification $notification); |
| 46 | } |