class QueueRoutes (View source)

Properties

protected array<class-string,string> $routes

The mapping of class names to their default routes.

Methods

string|null
getConnection(object $queueable)

Get the queue connection that a given queueable instance should be routed to.

string|null
getQueue(object $queueable)

Get the queue that a given queueable instance should be routed to.

string|null
getRoute(object $queueable)

Get the queue that a given queueable instance should be routed to.

void
set(array|string $class, string|null $queue = null, string|null $connection = null)

Register the queue route for the given class.

array
all()

Get all registered queue routes.

Details

string|null getConnection(object $queueable)

Get the queue connection that a given queueable instance should be routed to.

Parameters

object $queueable

Return Value

string|null

string|null getQueue(object $queueable)

Get the queue that a given queueable instance should be routed to.

Parameters

object $queueable

Return Value

string|null

string|null getRoute(object $queueable)

Get the queue that a given queueable instance should be routed to.

Parameters

object $queueable

Return Value

string|null

void set(array|string $class, string|null $queue = null, string|null $connection = null)

Register the queue route for the given class.

Parameters

array|string $class
string|null $queue
string|null $connection

Return Value

void

array all()

Get all registered queue routes.

Return Value

array