MCPcopy Create free account
hub / github.com/KDE/kdevelop / setFileContents

Method setFileContents

kdevplatform/tests/testfile.cpp:58–66  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

56 }
57
58 void setFileContents(const QString& contents)
59 {
60 QFile file(this->file);
61 file.open(QIODevice::WriteOnly | QIODevice::Truncate);
62 Q_ASSERT(file.isOpen());
63 Q_ASSERT(file.isWritable());
64 file.write(contents.toUtf8());
65 ready = false;
66 }
67
68 QString file;
69 QString suffix;

Callers

nothing calls this directly

Calls 3

openMethod · 0.45
isWritableMethod · 0.45
writeMethod · 0.45

Tested by

no test coverage detected