Вход Регистрация
Файл: gapps/vendor/laravel/framework/src/Illuminate/Queue/ConsoleServiceProvider.php
Строк: 68
<?php

namespace IlluminateQueue;

use 
IlluminateSupportServiceProvider;
use 
IlluminateQueueConsoleRetryCommand;
use 
IlluminateQueueConsoleListFailedCommand;
use 
IlluminateQueueConsoleFlushFailedCommand;
use 
IlluminateQueueConsoleForgetFailedCommand;

class 
ConsoleServiceProvider extends ServiceProvider
{
    
/**
     * Indicates if loading of the provider is deferred.
     *
     * @var bool
     */
    
protected $defer true;

    
/**
     * Register the service provider.
     *
     * @return void
     */
    
public function register()
    {
        
$this->app->singleton('command.queue.failed', function () {
            return new 
ListFailedCommand;
        });

        
$this->app->singleton('command.queue.retry', function () {
            return new 
RetryCommand;
        });

        
$this->app->singleton('command.queue.forget', function () {
            return new 
ForgetFailedCommand;
        });

        
$this->app->singleton('command.queue.flush', function () {
            return new 
FlushFailedCommand;
        });

        
$this->commands(
            
'command.queue.failed''command.queue.retry',
            
'command.queue.forget''command.queue.flush'
        
);
    }

    
/**
     * Get the services provided by the provider.
     *
     * @return array
     */
    
public function provides()
    {
        return [
            
'command.queue.failed''command.queue.retry',
            
'command.queue.forget''command.queue.flush',
        ];
    }
}
Онлайн: 0
Реклама