Set templex template engine URL features
@return void
496390
private function setTemplexFeatures(): void
    {
        $url = $this->getSchemeAndHttpHost();
        $sub = null;
        if ($this->getInterfaceSlug() && Str::length($this->getInterfaceSlug()) > 0) {
            $sub = $this->getInterfaceSlug() . '/';
        }

        if ($this->languageInPath()) {
            $sub .= $this->getLanguage();
        }

        UrlRepository::factory()->setUrlAndSubdir($url, $sub);
    }
929690
private function addTemplateFunctions()
    {
        //Asignamos las funciones especiales
        $functions = [
            'asset' => TemplateFunctions::ASSETS_FUNCTION,
            'form' => TemplateFunctions::FORM_FUNCTION,
            'form_widget' => TemplateFunctions::WIDGET_FUNCTION,
            'form_button' => TemplateFunctions::BUTTON_FUNCTION,
            'get_config' => TemplateFunctions::CONFIG_FUNCTION,
            'path' => TemplateFunctions::ROUTE_FUNCTION,
            'resource' => TemplateFunctions::RESOURCE_FUNCTION,
            'session' => TemplateFunctions::SESSION_FUNCTION,
            'existsFlash' => TemplateFunctions::EXISTS_FLASH_FUNCTION,
            'getFlash' => TemplateFunctions::GET_FLASH_FUNCTION,
            'getQuery' => TemplateFunctions::GET_QUERY_FUNCTION,
        ];
        foreach($functions as $name => $function) {
            $this->addTemplateFunction($name, $function);
        }
    }
1283689
public function setUrl ($url)
		{
			$this->authUrl = $url . '/oauth/authorize';
			$this->tokenUrl = $url . '/oauth/token';
			$this->apiBaseUrl = $url . '/api';
		}
385988
public function setTemplatePathAndFilename($templatePathAndFilename)
    {
        $this->baseRenderingContext->getTemplatePaths()->setTemplatePathAndFilename($templatePathAndFilename);

        $partialRootPaths = $this->baseRenderingContext->getTemplatePaths()->getPartialRootPaths();
        $layoutRootPaths = $this->baseRenderingContext->getTemplatePaths()->getLayoutRootPaths();
        array_unshift($partialRootPaths, Files::concatenatePaths([dirname($templatePathAndFilename), 'Partials']));
        array_unshift($layoutRootPaths, Files::concatenatePaths([dirname($templatePathAndFilename), 'Layouts']));
        $this->baseRenderingContext->getTemplatePaths()->setPartialRootPaths($partialRootPaths);
        $this->baseRenderingContext->getTemplatePaths()->setLayoutRootPaths($layoutRootPaths);
    }
854103
public function hasRoutableTemplates()
    {
        $this->buildTemplateIndex();

        $routable = false;

        foreach ($this->templateIndex as $name => $template) {
            if (($name !== self::INDEX_TEMPLATE) && ($name !== self::NOTFOUND_TEMPLATE)) {
                $routable = true;
                break;
            }
        }

        return($routable);
    }
375803
private function setUrl() {

		$url = Router :: url($this -> identifier, $this -> params);

		if(strlen($url) > 0) {
			$url = '/' . $url;
		}

		Request :: setURI($url);
		Router :: setUrl($url);
	}
775228
protected function addTemplateAssets($template)
    {
        /** @var SplFileInfo $file_info */
        foreach ($template->getAssets() as $filename => $file_info) {
            $this->assets->set($filename, $file_info->getRelativePathname());
        }
    }
928286
private function setTemplatesPath($templatesPath)
    {
        $this->templatesPath = $templatesPath;
        if (!is_readable($this->templatesPath)) {
            $this->error("Template Root Path ({$this->templatesPath}) does not exist or not readable.");
        }
    }
1218247
private function setCachePath()
    {
        $cachePath = __DIR__ . '/../../.cache';

        if ( ! is_dir($cachePath))
        {
            mkdir($cachePath);
            chmod($cachePath, 0777);
        }

        phpFastCache::setup("path", $cachePath);
        phpFastCache::setup("htaccess", false);
    }
1205047
public function setPageTemplate($template_path)
    {
        // Exclude post types
        $excludedPostTypes = array();
        if (has_filter('Municipio/CustomPostType/ExcludedPostTypes')) {
            $excludedPostTypes = apply_filters('Municipio/CustomPostType/ExcludedPostTypes', $excludedPostTypes);
        }

        if ($post_type = get_post_type()) {
            $post_type_object = get_post_type_object($post_type);

            if (is_object($post_type_object) && $post_type_object->hierarchical == true && $post_type_object->_builtin == false && !in_array($post_type_object->name, $excludedPostTypes)) {
                $template_path = \Municipio\Helper\Template::locateTemplate('page');
            }
        }

        return($template_path);
    }
673417
public function set_url() {

		$plugins_url = plugins_url();
		$this_url    = trim( substr( trailingslashit( plugin_dir_url( __FILE__ ) ), strlen( $plugins_url ) ), '/' );

		if ( false !== strpos( $this_url, '/' ) ) {
			$url_path = explode( '/', $this_url );
			// generic 3 path depth: classes/namespace/ui|data.
			array_splice( $url_path, count( $url_path ) - 3 );
			$this_url = implode( '/', $url_path );
		}
		// setup the base URL.
		$this->url = trailingslashit( $plugins_url . '/' . $this_url );
	}
833862
public function setUrl ($url)
		{
			$this->_url = $url;
			$this->_logoutUrl = $url . '/user/logout/';
			$this->authUrl = $url . '/oauth2/authorize';
			$this->tokenUrl = $url . '/oauth/token';
			$this->apiBaseUrl = $url . '/oauth';
		}
677752
public function set_template($template)
	{
		// make sure the template is a View
		if (is_string($template))
		{
			$this->template = $this->view($template);
		}
		else
		{
			$this->template = $template;
		}

		// return the template view for chaining
		return $this->template;
	}
256970
public function setTemplateDir($dirs): Sdopx
    {
        $this->templateDirs = [];
        $this->templateJoined = '';
        if (empty($dirs)) {
            return $this;
        }
        if (is_string($dirs)) {
            $this->templateDirs[] = $dirs;
            return $this;
        } elseif (is_array($dirs)) {
            foreach ($dirs as $key => $value) {
                if (!is_string($value) || empty($value)) {
                    continue;
                }
                $this->templateDirs[$key] = $value;
            }
        }
        return $this;
    }
506185
private function setTemplate()
    {
        $this->template = $this->formHelper->getConfig($this->getTemplate(), $this->getTemplate());
    }
830279
public function setPrefix($prefix)
    {
        if ($prefix != '') {
            $urlParts = parse_url($prefix);

            // Since PHP 5.4.7 parse_url will return host when url scheme is ommited.
            // This allows urls like //static.example.com to be used
            if (isset($urlParts['scheme']) || isset($urlParts['host'])) {
                $prefix = rtrim($prefix, '/') . '/';
            } else {
                $prefix = '/' . trim($prefix, '/') . '/';
            }
        }

        $this->prefix = $prefix;
    }
899931
public function setTemplating($templating)
    {
        if (null !== $templating && !$templating instanceof EngineInterface && !$templating instanceof Environment) {
            throw new \InvalidArgumentException('The hinclude rendering strategy needs an instance of Twig\Environment or Symfony\Component\Templating\EngineInterface');
        }

        if ($templating instanceof EngineInterface) {
            @trigger_error(sprintf('Using a "%s" instance for "%s" is deprecated since version 4.3; use a \Twig\Environment instance instead.', EngineInterface::class, __CLASS__), E_USER_DEPRECATED);
        }

        $this->templating = $templating;
    }