public function matchUri(string $uri): bool
    {
        $pattern = implode("\/", $this->patternParts);
        return preg_match("/^{$pattern}$/i", $this->stripLeadingAndTrailingSlash($uri)) != false;
    }