YetAnotherRandomObject::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 3
c 1
b 0
f 0
nc 1
nop 3
dl 0
loc 8
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace AHJ\ApprovalTests\Tests\Example;
6
7
final class YetAnotherRandomObject
8
{
9
    public string $dirPath;
10
11
    public int $fileNumber;
12
13
    public RandomObject $randomObject;
14
15
    public function __construct(
16
        string $dirPath,
17
        int $fileNumber,
18
        RandomObject $randomObject
19
    ) {
20
        $this->dirPath = $dirPath;
21
        $this->fileNumber = $fileNumber;
22
        $this->randomObject = $randomObject;
23
    }
24
25
    public function getDirPath(): string
26
    {
27
        return $this->dirPath;
28
    }
29
30
    public function getFileNumber(): int
31
    {
32
        return $this->fileNumber;
33
    }
34
35
    public function getYetAnotherRandomObject(): RandomObject
36
    {
37
        return $this->randomObject;
38
    }
39
}
40