| 76 | } |
| 77 | |
| 78 | void Project::writeProject(const QString& filename) |
| 79 | { |
| 80 | auto* file=new QFile(filename); |
| 81 | if(!file->open(QIODevice::WriteOnly)) { |
| 82 | return; |
| 83 | } |
| 84 | QXmlStreamWriter xml(file); |
| 85 | xml.setAutoFormatting(true); |
| 86 | xml.writeStartDocument(); |
| 87 | xml.writeStartElement("project"); |
| 88 | xml.writeAttribute("version","0.1"); |
| 89 | xml.writeTextElement("name",name); |
| 90 | for(const auto& source: getSources()) |
| 91 | xml.writeTextElement("source",source); |
| 92 | xml.writeEndElement(); |
| 93 | xml.writeEndDocument(); |
| 94 | delete file; |
| 95 | } |
| 96 | |
| 97 | void Project::setName(const QString& value) |
| 98 | { |
nothing calls this directly
no outgoing calls
no test coverage detected