public function validate(string $requestUri, string $requestMethod): bool
    {
        $route = $this->findRoute($this->filterUri($requestUri), $requestMethod);

        if ($route instanceof Route) {
            $this->buildValidRoute($route);
            return true;
        }

        $this->buildErrorRoute();

        return false;
    }
public function validate(string $requestUri, string $requestMethod): bool
    {
        $route = $this->findRoute($this->filterUri($requestUri), $requestMethod);

        if ($route instanceof Route) {
            $this->buildValidRoute($route);
            return true;
        }

        $this->buildErrorRoute();

        return false;
    }
public function validate ( string $ requestUri , string $ requestMethod ) : bool { $ route = $ this -> findRoute ( $ this -> filterUri ( $ requestUri ) , $ requestMethod ) ; if ( $ route instanceof Route ) { $ this -> buildValidRoute ( $ route ) ; return true ; } $ this -> buildErrorRoute ( ) ; return false ; }
Evaluate request uri.

@param string $requestUri
@param string $requestMethod

@return bool
Evaluate request uri .