private function compareUri(string $routeUri, string $requestUri, array &$parameters): bool
    {
        $pattern = '@^'.$this->regexUri($routeUri).'$@';

        return preg_match($pattern, $requestUri, $parameters);
    }