src/Rocketeer/Services/Builders/Modules/TasksBuilder.php
protected function buildTaskFromCallable($callable)
    {
        $task = new ClosureTask();
        $task->setContainer($this->container);
        $task->setClosure(function () use ($callable, $task) {
            list($class, $method) = is_array($callable) ? $callable : explode('::', $callable);

            return $this->getContainer()->get($class)->$method($task);
        });

        return $task;
    }
protected function buildTaskFromCallable($callable)
    {
        $task = new ClosureTask();
        $task->setContainer($this->container);
        $task->setClosure(function () use ($callable, $task) {
            list($class, $method) = is_array($callable) ? $callable : explode('::', $callable);

            return $this->getContainer()->get($class)->$method($task);
        });

        return $task;
    }
protected function buildTaskFromCallable ( $ callable ) { $ task = new ClosureTask ( ) ; $ task -> setContainer ( $ this -> container ) ; $ task -> setClosure ( function ( ) use ( $ callable , $ task ) { list ( $ class , $ method ) = is_array ( $ callable ) ? $ callable : explode ( '::' , $ callable ) ; return $ this -> getContainer ( ) -> get ( $ class ) -> $ method ( $ task ) ; } ) ; return $ task ; }
Build a task from a callable.

@param callable $callable

@return ClosureTask
Build a task from a callable .