protected function ContentAwareGenerator::getRouteByName in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/symfony-cmf/routing/ContentAwareGenerator.php \Symfony\Cmf\Component\Routing\ContentAwareGenerator::getRouteByName()
Get the route by a string name
Parameters
string $route:
array $parameters:
Return value
Throws
RouteNotFoundException if there is no route found for the provided name
1 call to ContentAwareGenerator::getRouteByName()
- ContentAwareGenerator::generate in vendor/
symfony-cmf/ routing/ ContentAwareGenerator.php
File
- vendor/
symfony-cmf/ routing/ ContentAwareGenerator.php, line 98
Class
- ContentAwareGenerator
- A generator that tries to generate routes from object, route names or content objects or names.
Namespace
Symfony\Cmf\Component\RoutingCode
protected function getRouteByName($name, array $parameters) {
$route = $this->provider
->getRouteByName($name);
if (empty($route)) {
throw new RouteNotFoundException('No route found for name: ' . $name);
}
return $this
->getBestLocaleRoute($route, $parameters);
}