OpenMS
Loading...
Searching...
No Matches
UnimodXMLDataProvider Class Reference

Loads ResidueModification data from a Unimod XML file. More...

#include <OpenMS/CHEMISTRY/UnimodXMLDataProvider.h>

Inheritance diagram for UnimodXMLDataProvider:
[legend]
Collaboration diagram for UnimodXMLDataProvider:
[legend]

Public Member Functions

 UnimodXMLDataProvider (const String &filename)
 
std::vector< std::unique_ptr< ResidueModification > > loadModifications () override
 Load modifications from whatever source this provider wraps.
 
- Public Member Functions inherited from ModificationDataProvider
virtual ~ModificationDataProvider ()=default
 

Private Attributes

String filename_
 

Detailed Description

Loads ResidueModification data from a Unimod XML file.

Wraps UnimodXMLFile::load() behind the ModificationDataProvider interface. Each modification gets its FullId set after parsing.

Constructor & Destructor Documentation

◆ UnimodXMLDataProvider()

UnimodXMLDataProvider ( const String filename)
explicit
Parameters
filenamePath to a Unimod XML file (resolved via File::find)

Member Function Documentation

◆ loadModifications()

std::vector< std::unique_ptr< ResidueModification > > loadModifications ( )
overridevirtual

Load modifications from whatever source this provider wraps.

Returns
Vector of modifications with ownership transferred to caller.
Note
Providers may only be called once. Subsequent calls may return empty results.

Implements ModificationDataProvider.

Member Data Documentation

◆ filename_

String filename_
private