Find the route using the provided route name (and parameters).
string $name: The route name to fetch
array $parameters: The parameters as they are passed to the UrlGeneratorInterface::generate call.
\Symfony\Component\Routing\Route The found route.
\Symfony\Component\Routing\Exception\RouteNotFoundException Thrown if there is no route with that name in this repository.
Overrides RouteProviderInterface::getRouteByName
public function getRouteByName($name, $parameters = array()) {
$routes = $this
->getRoutesByNames(array(
$name,
), $parameters);
if (empty($routes)) {
throw new RouteNotFoundException(sprintf('Route "%s" does not exist.', $name));
}
return reset($routes);
}