MCPcopy Create free account
hub / github.com/Kistler-Group/sdbus-cpp / writeToFile

Method writeToFile

tools/xml2cpp-codegen/BaseGenerator.cpp:53–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51
52
53int BaseGenerator::writeToFile(const char* filename, const std::string& data) const
54{
55 std::ofstream file(filename);
56 if (file.fail())
57 {
58 std::cerr << "Unable to write file " << filename << endl;
59 return 1;
60 }
61
62 file << data;
63 file.close();
64 return 0;
65}
66
67std::string BaseGenerator::createHeader(const char* filename, const StubType& stubType) const
68{

Callers

nothing calls this directly

Calls 1

closeMethod · 0.80

Tested by

no test coverage detected