public static function forMethod(string $class, string $method, array $classParameters = [], array $methodParameters = []) : RouteMatch
    {
        try {
            $controller = new \ReflectionMethod($class, $method);
        } catch (\ReflectionException $e) {
            throw RoutingException::invalidControllerClassMethod($e, $class, $method);
        }

        return new RouteMatch($controller, $classParameters, $methodParameters);
    }
public static function forMethod(string $class, string $method, array $classParameters = [], array $methodParameters = []) : RouteMatch
    {
        try {
            $controller = new \ReflectionMethod($class, $method);
        } catch (\ReflectionException $e) {
            throw RoutingException::invalidControllerClassMethod($e, $class, $method);
        }

        return new RouteMatch($controller, $classParameters, $methodParameters);
    }
public static function forMethod ( string $ class , string $ method , array $ classParameters = [ ] , array $ methodParameters = [ ] ) : RouteMatch { try { $ controller = new \ ReflectionMethod ( $ class , $ method ) ; } catch ( \ ReflectionException $ e ) { throw RoutingException :: invalidControllerClassMethod ( $ e , $ class , $ method ) ; } return new RouteMatch ( $ controller , $ classParameters , $ methodParameters ) ; }
Returns a RouteMatch for the given class and method.

@param string $class
@param string $method
@param array  $classParameters
@param array  $methodParameters

@return RouteMatch The route match.

@throws RoutingException If the class or method does not exist.
Returns a RouteMatch for the given class and method .