GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

WorkerEvent   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 1
dl 0
loc 27
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getWorkerInstance() 0 4 1
1
<?php
2
namespace dmank\gearman\event;
3
4
use dmank\gearman\Worker;
5
use Symfony\Component\EventDispatcher\Event;
6
7
class WorkerEvent extends Event
8
{
9
    const EVENT_BEFORE_RUN = 'worker.before_run';
10
    const EVENT_AFTER_RUN = 'worker.after_run';
11
    const EVENT_ON_IO_WAIT = 'worker.on_io_wait';
12
    const EVENT_ON_NO_JOBS = 'worker.on_no_jobs';
13
    const EVENT_ON_WORK = 'worker.on_work';
14
    const EVENT_ON_BEFORE_DESTROY = 'worker.on_before_destroy';
15
16
    /**
17
     * @var Worker
18
     */
19
    private $worker;
20
21 8
    public function __construct(Worker $workerInstance)
22
    {
23 8
        $this->worker = $workerInstance;
24 8
    }
25
26
    /**
27
     * @return Worker
28
     */
29 2
    public function getWorkerInstance()
30
    {
31 2
        return $this->worker;
32
    }
33
}
34