Passed
Push — master ( da7684...88d58f )
by BruceScrutinizer
02:01
created

ResultProcessedFileEditable::getConflicts()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php declare(strict_types=1);
2
3
namespace NamespaceProtector\Result;
4
5
final class ResultProcessedFileEditable implements ResultProcessedFileEditableInterface
6
{
7
    /** @var string  */
8
    private $file;
9
10
    /** @var array<ErrorResult> */
11
    private $conflicts = [];
12
13
    public function __construct(string $file)
14
    {
15
        $this->file = $file;
16
    }
17
18
    public function getFileName(): String
19
    {
20
        return $this->file;
21
    }
22
23
    public function addConflic(ErrorResult $conflic): void
24
    {
25
        $this->conflicts[] = $conflic;
26
    }
27
28
    /** @return array<ErrorResult> */
29
    public function getConflicts(): array
30
    {
31
        return $this->conflicts;
32
    }
33
}
34