public function getRealDir($path, $rootDir)
    {
        if (!is_string($path)) {
            return false;
        }

        if ($this->isRelativePath($path)) {
            return realpath($rootDir . DIRECTORY_SEPARATOR . dirname($path));
        }

        return realpath(dirname($path));
    }
public function getRealDir($path, $rootDir)
    {
        if (!is_string($path)) {
            return false;
        }

        if ($this->isRelativePath($path)) {
            return realpath($rootDir . DIRECTORY_SEPARATOR . dirname($path));
        }

        return realpath(dirname($path));
    }
public function getRealDir ( $ path , $ rootDir ) { if ( ! is_string ( $ path ) ) { return false ; } if ( $ this -> isRelativePath ( $ path ) ) { return realpath ( $ rootDir . DIRECTORY_SEPARATOR . dirname ( $ path ) ) ; } return realpath ( dirname ( $ path ) ) ; }
Return real directory path.

@param string $path    path
@param string $rootDir absolute path to project root directory

@return false|string real directory path string if the path string is passed and real directory exists, false otherwise
Return real directory path .