public function setEngine($name): bool
    {
        $this->loadTemplateEngines();
        if (isset($this->engines[$name])) {
            $this->current_engine = $this->engines[$name];
            Logger::log('Set the Template Engine to '.$name);

            return true;
        }
        throw new LayoutException('Could not set engine. Engine does not exist', 1);
    }