Core/Routing/Router.php
public function execute($uri, $requestMethod)
    {
        foreach ($this->routes as $route) {
            if (true === $route->matches($uri, $requestMethod)) {
                return $route;
            }
        }
        return null;
    }
public function execute($uri, $requestMethod)
    {
        foreach ($this->routes as $route) {
            if (true === $route->matches($uri, $requestMethod)) {
                return $route;
            }
        }
        return null;
    }
public function execute ( $ uri , $ requestMethod ) { foreach ( $ this -> routes as $ route ) { if ( true === $ route -> matches ( $ uri , $ requestMethod ) ) { return $ route ; } } return null ; }
Check routes and returns matching one if found,
otherwise return null.

@var string $uri
@var string $requestMethod
@return null|RouteInterface
Check routes and returns matching one if found otherwise return null .