| 40 | } |
| 41 | |
| 42 | void IndexedMzMLFileLoader::store(const String& filename, OnDiscPeakMap& exp) |
| 43 | { |
| 44 | // Create a writing data consumer which consumes the experiment (writes it to disk) |
| 45 | PlainMSDataWritingConsumer consumer(filename); |
| 46 | consumer.setExpectedSize(exp.getNrSpectra(), exp.getNrChromatograms()); |
| 47 | consumer.setExperimentalSettings(*exp.getExperimentalSettings().get()); |
| 48 | options_.setWriteIndex(true); // ensure that we write the index |
| 49 | consumer.setOptions(options_); |
| 50 | for (Size i = 0; i < exp.getNrSpectra(); i++) |
| 51 | { |
| 52 | MSSpectrum s = exp.getSpectrum(i); |
| 53 | consumer.consumeSpectrum(s); |
| 54 | } |
| 55 | for (Size i = 0; i < exp.getNrChromatograms(); i++) |
| 56 | { |
| 57 | MSChromatogram c = exp.getChromatogram(i); |
| 58 | consumer.consumeChromatogram(c); |
| 59 | } |
| 60 | } |
| 61 | |
| 62 | void IndexedMzMLFileLoader::store(const String& filename, PeakMap& exp) |
| 63 | { |
nothing calls this directly
no test coverage detected