示例#1
0
 public function load($name, $in = null, $baseTemplate = false)
 {
     if (substr($name, 0, 2) == './') {
         $name = $this->uriPath . substr($name, 2);
     }
     return $this->generator->load($name, $in, $baseTemplate);
 }
示例#2
0
 public function templates()
 {
     if (!($tool = $this->_getAppTool(__FUNCTION__, __CLASS__))) {
         $tool = new TemplateGenerator();
         $tool->app = $this->app;
         $tool->setTemplateContext(new AclTemplateContext());
         $tool->defaultModule = $this->module;
         $this->_setAppTool(__FUNCTION__, $tool);
     }
     return $tool;
 }
示例#3
0
 /** @return TemplateGenerator */
 public function appTemplates()
 {
     if ($tool = $this->_getAppTool(__FUNCTION__, __CLASS__)) {
         return $tool;
     }
     $tool = new TemplateGenerator();
     $tool->app = $this->app;
     $tool->setTemplateContext(new AppTemplateContext());
     $this->_setAppTool(__FUNCTION__, $tool);
     return $tool;
 }