PHPDaemon\Examples\ExampleComplexJob::baz PHP Method

baz() final public method

final public baz ( )
    public final function baz()
    {
        return function ($jobname, $job) {
            \PHPDaemon\Core\Timer::add(function ($event) use($jobname, $job) {
                // Job done
                $job->setResult($jobname, ['job' => 'baz', 'success' => false, 'line' => __LINE__]);
                $event->finish();
            }, 1000.0 * 300);
        };
    }
ExampleComplexJob