public function isDir(string $name)
    {
        $current = $this->pwd();
        try {
            $this->chDir($name);
            $this->chDir($current);
            return true;
        } catch (\Exception $e) {
            // do nothing
        }
        return false;
    }
public function isDir(string $name)
    {
        $current = $this->pwd();
        try {
            $this->chDir($name);
            $this->chDir($current);
            return true;
        } catch (\Exception $e) {
            // do nothing
        }
        return false;
    }
public function isDir ( string $ name ) { $ current = $ this -> pwd ( ) ; try { $ this -> chDir ( $ name ) ; $ this -> chDir ( $ current ) ; return true ; } catch ( \ Exception $ e ) { // do nothing } return false ; }
Determine if file is a directory.

@param  string $name
@return bool
Determine if file is a directory .