ApiPlatform\Core\Bridge\Symfony\Routing\OperationMethodResolver::getRoute PHP Method

getRoute() private method

Gets the route with the given name.
private getRoute ( string $routeName ) : Symfony\Component\Routing\Route
$routeName string
return Symfony\Component\Routing\Route
    private function getRoute(string $routeName) : Route
    {
        foreach ($this->router->getRouteCollection() as $name => $route) {
            if ($routeName === $name) {
                return $route;
            }
        }
        throw new RuntimeException(sprintf('The route "%s" does not exist.', $routeName));
    }