Documentation

ChannelManager extends Manager
in package
implements Dispatcher, Factory

Interfaces, Classes and Traits

Dispatcher
Factory

Table of Contents

$app  : Application
The application instance.
$customCreators  : array<string|int, mixed>
The registered custom driver creators.
$defaultChannel  : string
The default channel used to deliver messages.
$drivers  : array<string|int, mixed>
The array of created "drivers".
__call()  : mixed
Dynamically call the default driver instance.
__construct()  : void
Create a new manager instance.
channel()  : mixed
Get a channel instance.
deliversVia()  : string
Get the default channel driver name.
deliverVia()  : void
Set the default channel driver name.
driver()  : mixed
Get a driver instance.
extend()  : $this
Register a custom driver creator Closure.
getDefaultDriver()  : string
Get the default channel driver name.
getDrivers()  : array<string|int, mixed>
Get all of the created "drivers".
send()  : void
Send the given notification to the given notifiable entities.
sendNow()  : void
Send the given notification immediately.
callCustomCreator()  : mixed
Call a custom driver creator.
createBroadcastDriver()  : BroadcastChannel
Create an instance of the broadcast driver.
createDatabaseDriver()  : DatabaseChannel
Create an instance of the database driver.
createDriver()  : mixed
Create a new driver instance.
createMailDriver()  : MailChannel
Create an instance of the mail driver.
createNexmoDriver()  : NexmoSmsChannel
Create an instance of the Nexmo driver.
createSlackDriver()  : SlackWebhookChannel
Create an instance of the Slack driver.

Properties

$customCreators

The registered custom driver creators.

protected array<string|int, mixed> $customCreators = []

$defaultChannel

The default channel used to deliver messages.

protected string $defaultChannel = 'mail'

$drivers

The array of created "drivers".

protected array<string|int, mixed> $drivers = []

Methods

__call()

Dynamically call the default driver instance.

public __call(string $method, array<string|int, mixed> $parameters) : mixed
Parameters
$method : string
$parameters : array<string|int, mixed>
Return values
mixed

channel()

Get a channel instance.

public channel([string|null $name = null ]) : mixed
Parameters
$name : string|null = null
Return values
mixed

deliversVia()

Get the default channel driver name.

public deliversVia() : string
Return values
string

deliverVia()

Set the default channel driver name.

public deliverVia(string $channel) : void
Parameters
$channel : string
Return values
void

driver()

Get a driver instance.

public driver([string $driver = null ]) : mixed
Parameters
$driver : string = null
Return values
mixed

extend()

Register a custom driver creator Closure.

public extend(string $driver, Closure $callback) : $this
Parameters
$driver : string
$callback : Closure
Return values
$this

getDefaultDriver()

Get the default channel driver name.

public getDefaultDriver() : string
Return values
string

getDrivers()

Get all of the created "drivers".

public getDrivers() : array<string|int, mixed>
Return values
array<string|int, mixed>

send()

Send the given notification to the given notifiable entities.

public send(Collection|array<string|int, mixed>|mixed $notifiables, mixed $notification) : void
Parameters
$notifiables : Collection|array<string|int, mixed>|mixed
$notification : mixed
Return values
void

sendNow()

Send the given notification immediately.

public sendNow(Collection|array<string|int, mixed>|mixed $notifiables, mixed $notification[, array<string|int, mixed>|null $channels = null ]) : void
Parameters
$notifiables : Collection|array<string|int, mixed>|mixed
$notification : mixed
$channels : array<string|int, mixed>|null = null
Return values
void

callCustomCreator()

Call a custom driver creator.

protected callCustomCreator(string $driver) : mixed
Parameters
$driver : string
Return values
mixed

createDriver()

Create a new driver instance.

protected createDriver(string $driver) : mixed
Parameters
$driver : string
Tags
throws
InvalidArgumentException
Return values
mixed

Search results