1 | <?php |
||
19 | abstract class AbstractDashboardBlock implements ContainerAwareInterface |
||
20 | { |
||
21 | /** |
||
22 | * @var TwigEngine |
||
23 | */ |
||
24 | private $templating; |
||
25 | |||
26 | /** |
||
27 | * @var ContainerInterface |
||
28 | */ |
||
29 | private $container; |
||
30 | |||
31 | /** |
||
32 | * @var string |
||
33 | */ |
||
34 | protected $template; |
||
35 | |||
36 | /** |
||
37 | * @var array |
||
38 | */ |
||
39 | protected $templateParameters = []; |
||
40 | |||
41 | /** |
||
42 | * handleParameters should handle $templateParameters. It will be called when |
||
43 | * the block template will be rendered. Please override this method to set |
||
44 | * the view parameters of your block. |
||
45 | */ |
||
46 | public function handleParameters() |
||
50 | |||
51 | /** |
||
52 | * @param string $template |
||
53 | */ |
||
54 | public function __construct($template = null) |
||
58 | |||
59 | /** |
||
60 | * @return string The content of rendered template |
||
61 | */ |
||
62 | public function render() |
||
68 | |||
69 | /** |
||
70 | * @return TwigEngine |
||
71 | */ |
||
72 | public function getTemplating() |
||
76 | |||
77 | /** |
||
78 | * @param TwigEngine templating |
||
79 | * |
||
80 | * @return self |
||
81 | */ |
||
82 | public function setTemplating(TwigEngine $templating) |
||
88 | |||
89 | /** |
||
90 | * @return ContainerInterface |
||
91 | */ |
||
92 | public function getContainer() |
||
96 | |||
97 | /** |
||
98 | * @param ContainerInterface container |
||
99 | * |
||
100 | * @return self |
||
101 | */ |
||
102 | public function setContainer(ContainerInterface $container = null) |
||
108 | |||
109 | /** |
||
110 | * @return string |
||
111 | */ |
||
112 | public function getTemplate() |
||
116 | |||
117 | /** |
||
118 | * @param string template |
||
119 | * |
||
120 | * @return self |
||
121 | */ |
||
122 | public function setTemplate($template) |
||
128 | |||
129 | /** |
||
130 | * @return string |
||
131 | */ |
||
132 | public function getTemplateParameters() |
||
136 | |||
137 | /** |
||
138 | * @param string templateParameters |
||
139 | * |
||
140 | * @return self |
||
141 | */ |
||
142 | public function setTemplateParameters($templateParameters) |
||
148 | } |
||
149 |