MCPcopy Create free account
hub / github.com/BYVoid/OpenCC / SerializeToFile

Function SerializeToFile

src/SerializableDict.hpp:42–49  ·  view source on GitHub ↗

* Serializes the dictionary and writes in to a file. */

Source from the content-addressed store, hash-verified

40 * Serializes the dictionary and writes in to a file.
41 */
42 virtual void SerializeToFile(const std::string& fileName) const {
43 FILE* fp = OpenSerializableFileUtf8(fileName, "wb");
44 if (fp == NULL) {
45 throw FileNotWritable(fileName);
46 }
47 SerializeToFile(fp);
48 fclose(fp);
49 }
50
51 template <typename DICT>
52 static bool TryLoadFromFile(const std::string& fileName,

Callers

nothing calls this directly

Calls 1

OpenSerializableFileUtf8Function · 0.85

Tested by

no test coverage detected