1 | <?php |
||
11 | class TemplateManager |
||
12 | { |
||
13 | /** @var array */ |
||
14 | private $map; |
||
15 | |||
16 | /** @var string */ |
||
17 | private $templatesDir; |
||
18 | |||
19 | /** @var array */ |
||
20 | private $monitoredComponents = []; |
||
21 | |||
22 | /** |
||
23 | * @param array $map |
||
24 | * @param string|NULL $templatesDir |
||
25 | */ |
||
26 | public function __construct(array $map = [], string $templatesDir = NULL) |
||
31 | |||
32 | /** |
||
33 | * @param string $presenterName |
||
34 | * @param string $lookupPath |
||
35 | * @param string $templateFile |
||
36 | * |
||
37 | * @return NULL|string |
||
38 | */ |
||
39 | public function getTemplate(string $presenterName, string $lookupPath, string $templateFile) |
||
53 | |||
54 | /** |
||
55 | * @param string $presenterName |
||
56 | * @param string $lookupPath |
||
57 | * |
||
58 | * @return void |
||
59 | */ |
||
60 | public function monitor(string $presenterName, string $lookupPath) |
||
64 | |||
65 | /** |
||
66 | * @param string $presenterName |
||
67 | * @param string $lookupPath |
||
68 | * |
||
69 | * @return bool |
||
70 | */ |
||
71 | public function isMonitored(string $presenterName, string $lookupPath) |
||
75 | |||
76 | |||
77 | /** |
||
78 | * @internal |
||
79 | * @param string $dir |
||
80 | * |
||
81 | * @return array |
||
82 | */ |
||
83 | public static function createMap(string $dir) |
||
99 | } |
||
100 |