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

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

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

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

        return $path;
    }
public function toAbsolutePath ( $ path , $ rootDir ) { if ( ! is_string ( $ path ) ) { return false ; } if ( $ this -> isRelativePath ( $ path ) ) { return $ rootDir . DIRECTORY_SEPARATOR . $ path ; } return $ path ; }
Cat file path.

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

@return false|string absolute path
Cat file path .