private function createWorker()
    {
        $worker = $this->factory->create();
        $worker->start();

        $this->workers->attach($worker, 0);
        return $worker;
    }
private function createWorker()
    {
        $worker = $this->factory->create();
        $worker->start();

        $this->workers->attach($worker, 0);
        return $worker;
    }
private function createWorker ( ) { $ worker = $ this -> factory -> create ( ) ; $ worker -> start ( ) ; $ this -> workers -> attach ( $ worker , 0 ) ; return $ worker ; }
Creates a worker and adds them to the pool.

@return Worker The worker created.
Creates a worker and adds them to the pool .