/**
  * @param sfEvent $event
  */
 public function listenToLoadFactoriesEvent(sfEvent $event)
 {
     /** @var sfContext $sfContext */
     sfTwigRenderEngine::addEngineToContext($event->getSubject());
 }
示例#2
0
 /**
  * Returns the Twig_Environment
  *
  * @return Twig_Environment
  */
 public function getEngine()
 {
     return sfTwigRenderEngine::getInstanceFromContext($this->context)->getTwig();
 }