public function complexity()
    {
        $dynamicPartsCount = substr_count($this->pattern, ':') + substr_count($this->pattern, '?');

        return (substr_count($this->pattern, '/') - $dynamicPartsCount) * 100 + $dynamicPartsCount;
    }
public function complexity()
    {
        $dynamicPartsCount = substr_count($this->pattern, ':') + substr_count($this->pattern, '?');

        return (substr_count($this->pattern, '/') - $dynamicPartsCount) * 100 + $dynamicPartsCount;
    }
public function complexity ( ) { $ dynamicPartsCount = substr_count ( $ this -> pattern , ':' ) + substr_count ( $ this -> pattern , '?' ) ; return ( substr_count ( $ this -> pattern , '/' ) - $ dynamicPartsCount ) * 100 + $ dynamicPartsCount ; }
Count the number of pattern segments for this rule.
Count the number of pattern segments for this rule .