public function getJob(ObjectId $id): Process
    {
        $result = $this->db->{$this->job_queue}->findOne([
            '_id' => $id,
        ], [
            'typeMap' => self::TYPE_MAP,
        ]);

        if (null === $result) {
            throw new JobNotFoundException('job '.$id.' was not found');
        }

        return new Process($result, $this, $this->events);
    }
public function getJob(ObjectId $id): Process
    {
        $result = $this->db->{$this->job_queue}->findOne([
            '_id' => $id,
        ], [
            'typeMap' => self::TYPE_MAP,
        ]);

        if (null === $result) {
            throw new JobNotFoundException('job '.$id.' was not found');
        }

        return new Process($result, $this, $this->events);
    }
public function getJob ( ObjectId $ id ) : Process { $ result = $ this -> db -> { $ this -> job_queue } -> findOne ( [ '_id' => $ id , ] , [ 'typeMap' => self :: TYPE_MAP , ] ) ; if ( null === $ result ) { throw new JobNotFoundException ( 'job ' . $ id . ' was not found' ) ; } return new Process ( $ result , $ this , $ this -> events ) ; }
Get job by Id.
Get job by Id .