PHP Класс SimpleSoftwareIO\SMS\SMS

Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$container Illuminate\Container\Container The IOC Container.
$driver SimpleSoftwareIO\SMS\Drivers\DriverInterface The Driver Interface instance.
$from string The global from address.
$queue Illuminate\Queue\QueueManager Holds the queue instance.

Открытые методы

Метод Описание
__construct ( SimpleSoftwareIO\SMS\Drivers\DriverInterface $driver ) Creates the SMS instance.
alwaysFrom ( $number ) Sets the number that message should always be sent from.
checkMessages ( array $options = [] ) : array Queries the provider for a list of messages.
driver ( $driver ) Changes the set SMS driver.
getMessage ( $messageId ) : IncomingMessage Gets a message by it's ID.
handleQueuedMessage ( Illuminate\Queue\Jobs\Job $job, array $data ) Handles a queue message.
later ( integer $delay, string $view, array $data, Closure | string $callback, null | string $queue = null ) Queues a message to be sent a later time.
laterOn ( null | string $queue, integer $delay, string $view, array $data, Closure | string $callback ) Queues a message to be sent a later time on a given queue.
queue ( string $view, array $data, Closure | string $callback, null | string $queue = null ) Queues a SMS message.
queueOn ( null | string $queue, string $view, array $data, Closure | string $callback ) Queues a SMS message to a given queue.
receive ( ) : IncomingMessage Receives a SMS via a push request.
send ( string $view, array $data, Closure $callback ) : OutgoingMessage Send a SMS.
setContainer ( Illuminate\Container\Container $container ) Sets the IoC container.
setQueue ( Illuminate\Queue\QueueManager $queue ) Set the queue manager instance.

Защищенные методы

Метод Описание
buildQueueCallable ( Closure | string $callback ) : string Builds the callable for a queue.
createOutgoingMessage ( ) : OutgoingMessage Creates a new Message instance.
getQueuedCallable ( array $data ) : mixed Gets the callable for a queued message.

Описание методов

__construct() публичный Метод

Creates the SMS instance.
public __construct ( SimpleSoftwareIO\SMS\Drivers\DriverInterface $driver )
$driver SimpleSoftwareIO\SMS\Drivers\DriverInterface

alwaysFrom() публичный Метод

Sets the number that message should always be sent from.
public alwaysFrom ( $number )
$number

buildQueueCallable() защищенный Метод

Builds the callable for a queue.
protected buildQueueCallable ( Closure | string $callback ) : string
$callback Closure | string The callback to be serialized
Результат string

checkMessages() публичный Метод

Queries the provider for a list of messages.
public checkMessages ( array $options = [] ) : array
$options array The options to pass onto a provider. See each provider for a list of options.
Результат array Returns an array of IncomingMessage objects.

createOutgoingMessage() защищенный Метод

Creates a new Message instance.
protected createOutgoingMessage ( ) : OutgoingMessage
Результат OutgoingMessage

driver() публичный Метод

Changes the set SMS driver.
public driver ( $driver )
$driver

getMessage() публичный Метод

Gets a message by it's ID.
public getMessage ( $messageId ) : IncomingMessage
$messageId The requested messageId.
Результат IncomingMessage

getQueuedCallable() защищенный Метод

Gets the callable for a queued message.
protected getQueuedCallable ( array $data ) : mixed
$data array
Результат mixed

handleQueuedMessage() публичный Метод

Handles a queue message.
public handleQueuedMessage ( Illuminate\Queue\Jobs\Job $job, array $data )
$job Illuminate\Queue\Jobs\Job
$data array

later() публичный Метод

Queues a message to be sent a later time.
public later ( integer $delay, string $view, array $data, Closure | string $callback, null | string $queue = null )
$delay integer The desired delay in seconds
$view string The desired view.
$data array An array of data to fill the view.
$callback Closure | string The callback to run on the Message class.
$queue null | string The desired queue to push the message to.

laterOn() публичный Метод

Queues a message to be sent a later time on a given queue.
public laterOn ( null | string $queue, integer $delay, string $view, array $data, Closure | string $callback )
$queue null | string The desired queue to push the message to.
$delay integer The desired delay in seconds
$view string The desired view.
$data array An array of data to fill the view.
$callback Closure | string The callback to run on the Message class.

queue() публичный Метод

Queues a SMS message.
public queue ( string $view, array $data, Closure | string $callback, null | string $queue = null )
$view string The desired view.
$data array An array of data to fill the view.
$callback Closure | string The callback to run on the Message class.
$queue null | string The desired queue to push the message to.

queueOn() публичный Метод

Queues a SMS message to a given queue.
public queueOn ( null | string $queue, string $view, array $data, Closure | string $callback )
$queue null | string The desired queue to push the message to.
$view string The desired view.
$data array An array of data to fill the view.
$callback Closure | string The callback to run on the Message class.

receive() публичный Метод

Receives a SMS via a push request.
public receive ( ) : IncomingMessage
Результат IncomingMessage

send() публичный Метод

Send a SMS.
public send ( string $view, array $data, Closure $callback ) : OutgoingMessage
$view string The desired view.
$data array The data that needs to be passed into the view.
$callback Closure The methods that you wish to fun on the message.
Результат OutgoingMessage The outgoing message that was sent.

setContainer() публичный Метод

Sets the IoC container.
public setContainer ( Illuminate\Container\Container $container )
$container Illuminate\Container\Container

setQueue() публичный Метод

Set the queue manager instance.
public setQueue ( Illuminate\Queue\QueueManager $queue )
$queue Illuminate\Queue\QueueManager

Описание свойств

$container защищенное свойство

The IOC Container.
protected Container,Illuminate\Container $container
Результат Illuminate\Container\Container

$driver защищенное свойство

The Driver Interface instance.
protected DriverInterface,SimpleSoftwareIO\SMS\Drivers $driver
Результат SimpleSoftwareIO\SMS\Drivers\DriverInterface

$from защищенное свойство

The global from address.
protected string $from
Результат string

$queue защищенное свойство

Holds the queue instance.
protected QueueManager,Illuminate\Queue $queue
Результат Illuminate\Queue\QueueManager