public function nameMatches($pattern, $caseSensitive = null, $flags = null)
    {
        if (null === $caseSensitive) {
            $caseSensitive = false;
        }
        if (null === $flags) {
            $flags = 0;
        }
        if (!$caseSensitive) {
            $flags = $flags | FNM_CASEFOLD;
        }

        return fnmatch($pattern, $this->name(), $flags);
    }
public function nameMatches($pattern, $caseSensitive = null, $flags = null)
    {
        if (null === $caseSensitive) {
            $caseSensitive = false;
        }
        if (null === $flags) {
            $flags = 0;
        }
        if (!$caseSensitive) {
            $flags = $flags | FNM_CASEFOLD;
        }

        return fnmatch($pattern, $this->name(), $flags);
    }
public function nameMatches ( $ pattern , $ caseSensitive = null , $ flags = null ) { if ( null === $ caseSensitive ) { $ caseSensitive = false ; } if ( null === $ flags ) { $ flags = 0 ; } if ( ! $ caseSensitive ) { $ flags = $ flags | FNM_CASEFOLD ; } return fnmatch ( $ pattern , $ this -> name ( ) , $ flags ) ; }
Determine if this path's name matches a wildcard pattern.

@param string       $pattern       The pattern to check against.
@param boolean|null $caseSensitive True if case sensitive.
@param integer|null $flags         Additional flags.

@return boolean True if this path's name matches the pattern.
Determine if this path s name matches a wildcard pattern .