Total Complexity | 6 |
Total Lines | 27 |
Duplicated Lines | 0 % |
Coverage | 75% |
Changes | 0 |
1 | <?php |
||
5 | class View |
||
6 | { |
||
7 | private static $view = null; |
||
8 | private static $data = []; |
||
9 | |||
10 | 2 | private static function view(): Tpl |
|
|
|||
11 | { |
||
12 | 2 | if (!isset(self::$view) || is_null(self::$view)) { |
|
13 | 2 | self::$view = new Tpl; |
|
14 | } |
||
15 | |||
16 | 2 | return self::$view; |
|
17 | } |
||
18 | |||
19 | 2 | public static function config(array $config): void |
|
20 | { |
||
21 | 2 | self::view()->config($config); |
|
22 | 2 | } |
|
23 | |||
24 | public static function assign(string $key, $value): void |
||
27 | } |
||
28 | |||
29 | 2 | public static function render(string $view, array $data = null): string |
|
32 | } |
||
33 | } |
||
34 |