public function buildUri(RouteData $routeData, $language = null) { $name = $routeData->getName(); if (!isset($this->routes[$name])) { throw new \Exception('route "' . $name . '" not found'); } $path = $this->routes[$name]->buildUri($routeData, $language); return $path; }