| 20 | MzTabMFile::~MzTabMFile()= default; |
| 21 | |
| 22 | void MzTabMFile::generateMzTabMMetaDataSection_(const MzTabMMetaData& md, StringList& sl) const |
| 23 | { |
| 24 | sl.push_back(String("MTD\tmzTab-version\t") + md.mz_tab_version.toCellString()); // mandatory |
| 25 | sl.push_back(String("MTD\tmzTab-ID\t") + md.mz_tab_id.toCellString()); // mandatory |
| 26 | |
| 27 | if (!md.title.isNull()) |
| 28 | { |
| 29 | String s = String("MTD\ttitle\t") + md.title.toCellString(); |
| 30 | sl.push_back(s); |
| 31 | } |
| 32 | |
| 33 | if(!md.description.isNull()) |
| 34 | { |
| 35 | String s = String("MTD\tdescription\t") + md.description.toCellString(); |
| 36 | sl.push_back(s); |
| 37 | } |
| 38 | |
| 39 | for (const auto& sp : md.sample_processing) |
| 40 | { |
| 41 | String s = "MTD\tsample_processing[" + String(sp.first) + "]\t" + sp.second.toCellString(); |
| 42 | sl.push_back(s); |
| 43 | } |
| 44 | |
| 45 | for (const auto& inst : md.instrument) |
| 46 | { |
| 47 | const MzTabInstrumentMetaData& imd = inst.second; |
| 48 | |
| 49 | if (!imd.name.isNull()) |
| 50 | { |
| 51 | String s = "MTD\tinstrument[" + String(inst.first) + "]-name\t" + imd.name.toCellString(); |
| 52 | sl.push_back(s); |
| 53 | } |
| 54 | |
| 55 | if (!imd.source.isNull()) |
| 56 | { |
| 57 | String s = "MTD\tinstrument[" + String(inst.first) + "]-source\t" + imd.source.toCellString(); |
| 58 | sl.push_back(s); |
| 59 | } |
| 60 | |
| 61 | for (const auto& mit : imd.analyzer) |
| 62 | { |
| 63 | if (!mit.second.isNull()) |
| 64 | { |
| 65 | String s = "MTD\tinstrument[" + String(inst.first) + "]-analyzer[" + String(mit.first) + "]\t" + mit.second.toCellString(); |
| 66 | sl.push_back(s); |
| 67 | } |
| 68 | } |
| 69 | |
| 70 | if (!imd.detector.isNull()) |
| 71 | { |
| 72 | String s = "MTD\tinstrument[" + String(inst.first) + "]-detector\t" + imd.detector.toCellString(); |
| 73 | sl.push_back(s); |
| 74 | } |
| 75 | } |
| 76 | |
| 77 | for (const auto & sw : md.software) |
| 78 | { |
| 79 | MzTabSoftwareMetaData msmd = sw.second; |
nothing calls this directly
no test coverage detected