CallQueuedHandler
class CallQueuedHandler (View source)
Properties
protected Dispatcher | $dispatcher | The bus dispatcher implementation. |
Methods
void | __construct(Dispatcher $dispatcher) Create a new handler instance. | |
void | call(Job $job, array $data) Handle the queued job. | |
mixed | resolveHandler(Job $job, mixed $command) Resolve the handler for the given command. | |
mixed | setJobInstanceIfNecessary(Job $job, mixed $instance) Set the job instance of the given class if necessary. | |
void | ensureNextJobInChainIsDispatched(mixed $command) Ensure the next job in the chain is dispatched if applicable. | |
void | handleModelNotFound(Job $job, Exception $e) Handle a model not found exception. | |
void | failed(array $data, Exception $e) Call the failed method on the job instance. |
Details
void __construct(Dispatcher $dispatcher)
Create a new handler instance.
void call(Job $job, array $data)
Handle the queued job.
protected mixed resolveHandler(Job $job, mixed $command)
Resolve the handler for the given command.
protected mixed setJobInstanceIfNecessary(Job $job, mixed $instance)
Set the job instance of the given class if necessary.
protected void ensureNextJobInChainIsDispatched(mixed $command)
Ensure the next job in the chain is dispatched if applicable.
void failed(array $data, Exception $e)
Call the failed method on the job instance.
The exception that caused the failure will be passed.
© Taylor Otwell
Licensed under the MIT License.
Laravel is a trademark of Taylor Otwell.
https://laravel.com/api/5.7/Illuminate/Queue/CallQueuedHandler.html