MCPcopy Create free account
hub / github.com/MJx0/KittyMemoryEx / writeToFile

Method writeToFile

KittyMemoryEx/KittyIOFile.hpp:308–312  ·  view source on GitHub ↗

* @brief Writes the contents of the file to another file. * * @param filePath The file path to write to. * @return true if the file was written successfully, false otherwise. */

Source from the content-addressed store, hash-verified

306 * @param str The string to read into.
307 * @return true if the file was read successfully, false otherwise.
308 */
309 inline static bool readFileToString(const std::string &filePath, std::string *str)
310 {
311 KittyIOFile f(filePath, O_RDONLY | O_CLOEXEC);
312 return f.open() && f.readToString(str);
313 }
314
315 /**

Callers 1

copyMethod · 0.80

Calls 2

openMethod · 0.80
fdMethod · 0.80

Tested by

no test coverage detected