Arcanedev\Localization\Localization::getUrlFromRouteName PHP Метод

getUrlFromRouteName() публичный Метод

Returns an URL adapted to the route name and the locale given.
public getUrlFromRouteName ( string $locale, string $transKey, array $attributes = [] ) : string | false
$locale string
$transKey string
$attributes array
Результат string | false
    public function getUrlFromRouteName($locale, $transKey, $attributes = [])
    {
        $this->isLocaleSupportedOrFail($locale);
        $route = $this->routeTranslator->getUrlFromRouteName($locale, $this->getDefaultLocale(), $transKey, $attributes, $this->isDefaultLocaleHiddenInUrl());
        // This locale does not have any key for this route name
        if (empty($route)) {
            return false;
        }
        return rtrim($this->createUrlFromUri($route));
    }