PostDispatchTaskEvent   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 37
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 7
c 1
b 0
f 0
dl 0
loc 37
ccs 0
cts 12
cp 0
rs 10
wmc 3

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getResult() 0 3 1
A getTask() 0 3 1
A __construct() 0 4 1
1
<?php
2
3
namespace Deployee\Plugins\Deploy\Events;
4
5
use Deployee\Plugins\Deploy\Definitions\Tasks\TaskDefinitionInterface;
6
use Deployee\Plugins\Deploy\Dispatcher\DispatchResultInterface;
7
use Symfony\Component\EventDispatcher\Event;
8
9
class PostDispatchTaskEvent extends Event
10
{
11
    /**
12
     * @var TaskDefinitionInterface
13
     */
14
    private $task;
15
16
    /**
17
     * @var DispatchResultInterface
18
     */
19
    private $result;
20
21
    /**
22
     * PostDispatchTaskEvent constructor.
23
     * @param TaskDefinitionInterface $task
24
     * @param DispatchResultInterface $result
25
     */
26
    public function __construct(TaskDefinitionInterface $task, DispatchResultInterface $result)
27
    {
28
        $this->task = $task;
29
        $this->result = $result;
30
    }
31
32
    /**
33
     * @return TaskDefinitionInterface
34
     */
35
    public function getTask(): TaskDefinitionInterface
36
    {
37
        return $this->task;
38
    }
39
40
    /**
41
     * @return DispatchResultInterface
42
     */
43
    public function getResult(): DispatchResultInterface
44
    {
45
        return $this->result;
46
    }
47
}