6#ifndef IFW_CORE_UTILS_FILE_HPP_
7#define IFW_CORE_UTILS_FILE_HPP_
18 const std::string& extension);
28 std::string
LoadFile(
const std::string& filename,
29 std::string* complete_filename =
nullptr);
37 void SaveFile(
const std::string& filename,
38 const std::string& buffer,
39 const bool overwrite =
true);
std::string CheckAddExtension(const std::string &filename, const std::string &extension)
Check if filename has the specified extension (no initiating dot). If not, add it.
Definition file.cpp:19
std::string LoadFile(const std::string &filename, std::string *complete_filename)
Load a file and return the content.
Definition file.cpp:46
void CheckCreatePath(const std::string &path)
Check if the given path exists. If not, create it.
Definition file.cpp:97
void SaveFile(const std::string &filename, const std::string &buffer, const bool overwrite)
Save the contents inthe buffer into the given filename.
Definition file.cpp:69
void RemoveFile(const std::string &filename)
Remove the referenced file, if it exists.
Definition file.cpp:29