/**
  * Gets a DecodaPhpEngine
  *
  * @return DecodaPhpEngine
  */
 private function getPhpEngine()
 {
     if (null === $this->phpEngine) {
         $this->phpEngine = new DecodaPhpEngine();
         foreach ($this->options['templates'] as $template) {
             // Use bundle hierachy
             $paths = $this->locator->locate($template['path'], null, false);
             krsort($paths);
             foreach ($paths as $path) {
                 $this->phpEngine->addPath($path);
             }
         }
     }
     return $this->phpEngine;
 }
 /**
  *
  * @return Decoda
  */
 public function getResult()
 {
     $decodaPhpEngine = new DecodaPhpEngine();
     foreach (static::$extra_paths as $extraPath) {
         $decodaPhpEngine->setpath($extraPath);
     }
     $this->value->setTemplateEngine($decodaPhpEngine);
     foreach ($this->filters as $filter) {
         $this->value = $this->apply_filter($this->value, $filter);
     }
     foreach ($this->hooks as $hook) {
         $this->value = $this->apply_hook($this->value, $hook);
     }
     $this->value = $this->apply_whitelist($this->value, $this->whitelist);
     return $this->value;
 }