1 | <?php |
||
11 | class TemplateHelper |
||
12 | { |
||
13 | /** @var \Twig_Environment */ |
||
14 | private $twig; |
||
15 | /** @var Filesystem */ |
||
16 | private $fileSystem; |
||
17 | /** @var string */ |
||
18 | private static $templateBasePath = null; |
||
19 | |||
20 | /** |
||
21 | * @param \Twig_Environment $twig |
||
22 | * @param array $varList |
||
23 | */ |
||
24 | public function __construct(\Twig_Environment $twig, array $varList) |
||
31 | |||
32 | /** |
||
33 | * @param string $template |
||
34 | * @param string $outputFilePath |
||
35 | */ |
||
36 | public function dumpTemplate($template, $outputFilePath) |
||
43 | |||
44 | public static function getTemplateBasePath() |
||
51 | |||
52 | /** |
||
53 | * @param array $varList |
||
54 | * |
||
55 | * @throws \Twig_Error_Loader |
||
56 | */ |
||
57 | private function initTwig(array $varList) |
||
83 | |||
84 | /** |
||
85 | * @param string $varName |
||
86 | * @param string $varValue |
||
87 | * |
||
88 | * @return array |
||
89 | */ |
||
90 | protected function resolveVar($varName, $varValue) |
||
100 | } |
||
101 |