framework/web/UrlManager.php
protected function getUrlFromCache($cacheKey, $route, $params)
    {
        if (!empty($this->_ruleCache[$cacheKey])) {
            foreach ($this->_ruleCache[$cacheKey] as $rule) {
                /* @var $rule UrlRule */
                if (($url = $rule->createUrl($this, $route, $params)) !== false) {
                    return $url;
                }
            }
        } else {
            $this->_ruleCache[$cacheKey] = [];
        }

        return false;
    }
protected function getUrlFromCache($cacheKey, $route, $params)
    {
        if (!empty($this->_ruleCache[$cacheKey])) {
            foreach ($this->_ruleCache[$cacheKey] as $rule) {
                /* @var $rule UrlRule */
                if (($url = $rule->createUrl($this, $route, $params)) !== false) {
                    return $url;
                }
            }
        } else {
            $this->_ruleCache[$cacheKey] = [];
        }

        return false;
    }
protected function getUrlFromCache ( $ cacheKey , $ route , $ params ) { if ( ! empty ( $ this -> _ruleCache [ $ cacheKey ] ) ) { foreach ( $ this -> _ruleCache [ $ cacheKey ] as $ rule ) { /* @var $rule UrlRule */ if ( ( $ url = $ rule -> createUrl ( $ this , $ route , $ params ) ) !== false ) { return $ url ; } } } else { $ this -> _ruleCache [ $ cacheKey ] = [ ] ; } return false ; }
Get URL from internal cache if exists.
@param string $cacheKey generated cache key to store data.
@param string $route the route (e.g. `site/index`).
@param array $params rule params.
@return bool|string the created URL
@see createUrl()
@since 2.0.8
Get URL from internal cache if exists .