Class FileSystem

Class Documentation

class Utilities::FileSystem

This class implements different file system functions.

Public Static Functions

std::string getFilePath(const std::string &path)
std::string getFileName(const std::string &path)
std::string getFileNameWithExt(const std::string &path)
std::string getFileExt(const std::string &path)
bool isRelativePath(const std::string &path)
int makeDir(const std::string &path)
int makeDirs(const std::string &path)

Make all subdirectories.

std::string normalizePath(const std::string &path)
bool fileExists(const std::string &fileName)
std::string getProgramPath()
bool copyFile(const std::string &source, const std::string &dest)
bool isFile(const std::string &path)
bool isDirectory(const std::string &path)
bool getFilesInDirectory(const std::string &path, std::vector<std::string> &res)
std::string getFileMD5(const std::string &filename)

Compute the MD5 hash of a file.

bool writeMD5File(const std::string &fileName, const std::string &md5File)

Write the MD5 hash of a file to the md5File.

bool checkMD5(const std::string &md5Hash, const std::string &md5File)

Compare an MD5 hash with the hash stored in an MD5 file.