mirror of
https://github.com/kiwix/libkiwix.git
synced 2025-06-26 10:11:30 +00:00
Introduce kiwix::fileReadable
kiwix::fileExists only checks for file existence now kiwix::fileReadable will check if the file is readable (implicitly checking for file existence also)
This commit is contained in:
@ -180,13 +180,22 @@ std::string getFileContent(const std::string& path);
|
||||
|
||||
/** checks if file exists.
|
||||
*
|
||||
* This function returns boolean stating if file exists or not.
|
||||
* This function returns boolean stating if file exists.
|
||||
*
|
||||
* @param path The absolute path provided in string format.
|
||||
* @return Boolean representing if file exists or not.
|
||||
*/
|
||||
bool fileExists(const std::string& path);
|
||||
|
||||
/** checks if file is readable.
|
||||
*
|
||||
* This function returns boolean stating if file is readable.
|
||||
*
|
||||
* @param path The absolute path provided in string format.
|
||||
* @return Boolean representing if file is readale or not.
|
||||
*/
|
||||
bool fileReadable(const std::string& path);
|
||||
|
||||
/** provides mimetype from filename.
|
||||
*
|
||||
* This function provides mimetype from file-name.
|
||||
|
Reference in New Issue
Block a user