GacelaConfigItem   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 22
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 4
dl 0
loc 22
rs 10
c 0
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A reader() 0 3 1
A __construct() 0 5 1
A pathLocal() 0 3 1
A path() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Gacela\Framework\Config\GacelaFileConfig;
6
7
use Gacela\Framework\Config\ConfigReader\PhpConfigReader;
8
use Gacela\Framework\Config\ConfigReaderInterface;
9
10
final class GacelaConfigItem
11
{
12
    public function __construct(
13
        private readonly string $path,
14
        private readonly string $pathLocal = '',
15
        private readonly ConfigReaderInterface $reader = new PhpConfigReader(),
16
    ) {
17
    }
18
19
    public function path(): string
20
    {
21
        return $this->path;
22
    }
23
24
    public function pathLocal(): string
25
    {
26
        return $this->pathLocal;
27
    }
28
29
    public function reader(): ConfigReaderInterface
30
    {
31
        return $this->reader;
32
    }
33
}
34