ScheduleAware.php in SMS Framework 8
File
tests/modules/sms_test_gateway/src/Plugin/SmsGateway/ScheduleAware.php
View source
<?php
namespace Drupal\sms_test_gateway\Plugin\SmsGateway;
use Drupal\sms\Entity\SmsMessageInterface as SmsMessageEntityInterface;
use Drupal\sms\Message\SmsMessageInterface;
class ScheduleAware extends Memory {
public function defaultConfiguration() {
return [];
}
public function send(SmsMessageInterface $sms) {
if ($sms instanceof SmsMessageEntityInterface) {
return parent::send($sms);
}
else {
throw new \Exception('Not a SMS message entity');
}
}
}
Classes
Name |
Description |
ScheduleAware |
Defines a gateway which is aware of scheduled send time. |