MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / load

Method load

src/openms/source/FORMAT/ConsensusXMLFile.cpp:81–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

79 }
80
81 void ConsensusXMLFile::load(const String& filename, ConsensusMap& consensus_map)
82 {
83 consensus_map.clear(true); // clear map
84
85 //set DocumentIdentifier
86 consensus_map.setLoadedFileType(filename);
87 consensus_map.setLoadedFilePath(filename);
88
89 Internal::ConsensusXMLHandler handler(consensus_map, filename);
90 handler.setOptions(options_);
91 handler.setLogType(getLogType());
92 parse_(filename, &handler);
93
94 if (!consensus_map.isMapConsistent(&OpenMS_Log_warn)) // a warning is printed to LOG_WARN during isMapConsistent()
95 {
96 // don't throw exception for now, since this would prevent us from reading old files...
97 // throw Exception::MissingInformation(__FILE__, __LINE__, OPENMS_PRETTY_FUNCTION, "The ConsensusXML file contains invalid maps or references thereof. Please fix the file!");
98
99 }
100
101 }
102
103} // namespace OpenMS

Callers 1

linkFunction · 0.95

Calls 6

setLoadedFileTypeMethod · 0.80
setLoadedFilePathMethod · 0.80
setLogTypeMethod · 0.80
isMapConsistentMethod · 0.80
clearMethod · 0.45
setOptionsMethod · 0.45

Tested by

no test coverage detected