Total Complexity | 3 |
Total Lines | 22 |
Duplicated Lines | 0 % |
Coverage | 0% |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
10 | class PhpReader extends AbstractReader implements ReaderWithParamsInterface |
||
11 | { |
||
12 | |||
13 | private array $params = []; |
||
14 | |||
15 | protected function readRaw(string $path) |
||
16 | { |
||
17 | $config = []; |
||
18 | foreach ($this->builder->getVars() as $key => $parameters) { |
||
19 | $config[$key] = $parameters; |
||
20 | } |
||
21 | |||
22 | $result = static function (array $params, array $config) { |
||
23 | return require func_get_arg(2); |
||
24 | }; |
||
25 | |||
26 | return $result($this->params, $config, $path); |
||
27 | } |
||
28 | |||
29 | public function setParams(array $params): void |
||
32 | } |
||
33 | } |
||
34 |