private function matchRule($route, RoutingRuleAbstract &$rule) {
        list($regex, $inputs) = $this->getRegexProperties($rule);

        $matches = array();
        preg_match($regex, $route, $matches);
        if (count($matches) > 0) {
            //Substract the first element of the array, which is the complete URL
            array_splice($matches, 0, 1);
            for ($i = 0; $i < count($inputs); $i++) {
                $key = $inputs[$i];
                $value = $matches[$i];
                $rule->getInput()->setInput($key, $value);
            }
            return true;
        }
        return false;
    }