The interface of a consumer of spectra and chromatograms.
Definition: IMSDataConsumer.h:70
Base class for loading/storing XML files that have a handler derived from XMLHandler.
Definition: XMLFile.h:49
Base class for XML handlers.
Definition: XMLHandler.h:327
In-Memory representation of a mass spectrometry experiment.
Definition: MSExperiment.h:80
File adapter for MzML files.
Definition: MzMLFile.h:58
void setOptions(const PeakFileOptions &)
set options for loading/storing
void transform(const String &filename_in, Interfaces::IMSDataConsumer *consumer, PeakMap &map, bool skip_full_count=false, bool skip_first_pass=false)
Transforms a map while loading using the supplied MSDataConsumer.
bool isValid(const String &filename, std::ostream &os=std::cerr)
Checks if a file validates against the XML schema.
const PeakFileOptions & getOptions() const
Non-mutable access to the options for loading/storing.
PeakFileOptions options_
Options for loading / storing.
Definition: MzMLFile.h:216
MzMLFile()
Default constructor.
void transformFirstPass_(const String &filename_in, Interfaces::IMSDataConsumer *consumer, bool skip_full_count)
Perform first pass through the file and retrieve the meta-data to initialize the consumer.
void safeParse_(const String &filename, Internal::XMLHandler *handler)
Safe parse that catches exceptions and handles them accordingly.
PeakFileOptions & getOptions()
Mutable access to the options for loading/storing.
void storeBuffer(std::string &output, const PeakMap &map) const
Stores a map in an output string.
String indexed_schema_location_
Location of indexed mzML schema.
Definition: MzMLFile.h:219
void transform(const String &filename_in, Interfaces::IMSDataConsumer *consumer, bool skip_full_count=false, bool skip_first_pass=false)
Transforms a map while loading using the supplied MSDataConsumer.
void loadBuffer(const std::string &buffer, PeakMap &map)
Loads a map from a MzML file stored in a buffer (in memory).
~MzMLFile() override
Destructor.
std::map< UInt, SpecInfo > getCentroidInfo(const String &filename, const Size first_n_spectra_only=10)
Check type of spectra based on their metadata (if available) or by inspecting the peaks itself.
void store(const String &filename, const PeakMap &map) const
Stores a map in an MzML file.
void loadSize(const String &filename, Size &scount, Size &ccount)
Only count the number of spectra and chromatograms from a file.
void load(const String &filename, PeakMap &map)
Loads a map from a MzML file. Spectra and chromatograms are sorted by default (this can be disabled u...
bool isSemanticallyValid(const String &filename, StringList &errors, StringList &warnings)
Checks if a file is valid with respect to the mapping file and the controlled vocabulary.
Definition: MzMLFile.h:180
Options for loading files containing peak data.
Definition: PeakFileOptions.h:48
Base class for all classes that want to report their progress.
Definition: ProgressLogger.h:55
A more convenient string class.
Definition: String.h:61
size_t Size
Size type e.g. used as variable which can hold result of size()
Definition: Types.h:127
std::vector< String > StringList
Vector of String.
Definition: ListUtils.h:70
Main OpenMS namespace.
Definition: FeatureDeconvolution.h:47