1 | <?php |
||
10 | class TemplateHelper |
||
11 | { |
||
12 | /** @var \Twig_Environment */ |
||
13 | private $twig; |
||
14 | /** @var Filesystem */ |
||
15 | private $fileSystem; |
||
16 | /** @var string */ |
||
17 | private static $templateBasePath = null; |
||
18 | |||
19 | /** |
||
20 | * @param \Twig_Environment $twig |
||
21 | * @param array $varList |
||
22 | */ |
||
23 | public function __construct(\Twig_Environment $twig, array $varList) |
||
30 | |||
31 | /** |
||
32 | * @param string $template |
||
33 | * @param string $outputFilePath |
||
34 | */ |
||
35 | public function dump($template, $outputFilePath) |
||
42 | |||
43 | public static function getTemplateBasePath() |
||
50 | |||
51 | /** |
||
52 | * @param array $varList |
||
53 | * |
||
54 | * @throws \Twig_Error_Loader |
||
55 | */ |
||
56 | private function initTwig(array $varList) |
||
86 | |||
87 | /** |
||
88 | * @param string $varName |
||
89 | * @param string $varValue |
||
90 | * |
||
91 | * @return array |
||
92 | */ |
||
93 | protected function resolveVar($varName, $varValue) |
||
103 | } |
||
104 |