Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Public Member Functions | Protected Member Functions

MSPFile Class Reference
[File IO]

File adapter for MSP files (NIST spectra library). More...

#include <OpenMS/FORMAT/MSPFile.h>

Inheritance diagram for MSPFile:
DefaultParamHandler

List of all members.

Public Member Functions

MSPFileoperator= (const MSPFile &rhs)
 assignment operator
void load (const String &filename, std::vector< PeptideIdentification > &ids, RichPeakMap &exp)
 Loads a map from a MSPFile file.
void store (const String &filename, const RichPeakMap &exp) const
 Stores a map in a MSPFile file.

 MSPFile ()
 Default constructor.
 MSPFile (const MSPFile &rhs)
 Copy constructor.
virtual ~MSPFile ()
 Destructor.

Protected Member Functions

void parseHeader_ (const String &header, RichPeakSpectrum &spec)
 reads the header information and stores it as metainfo in the spectrum

Detailed Description

File adapter for MSP files (NIST spectra library).

Parameters of this class are:

NameTypeDefaultRestrictionsDescription
parse_headers stringfalse true, falseFlag whether header information should be parsed an stored for each spectrum
parse_peakinfo stringtrue true, falseFlag whether the peak annotation information should be parsed and stored for each peak
instrument string , it, qtof, toftofIf instrument given, only spectra of these type of instrument (Inst= in header) are parsed

Note:

Constructor & Destructor Documentation

MSPFile (  ) 

Default constructor.

Constructors and destructors

MSPFile ( const MSPFile rhs  ) 

Copy constructor.

virtual ~MSPFile (  )  [virtual]

Destructor.


Member Function Documentation

void load ( const String filename,
std::vector< PeptideIdentification > &  ids,
RichPeakMap exp 
)

Loads a map from a MSPFile file.

Parameters:
exp RichPeakMap which contains the spectra after reading
filename the filename of the experiment
ids output parameter which contains the peptide identifications from the spectra anntations
Exceptions:
FileNotFound is thrown if the file could not be found
ParseError is thrown if the given file could not be parsed
ElementNotFound is thrown if a annotated modification cannot be found in ModificationsDB (PSI-MOD definitions)
MSPFile& operator= ( const MSPFile rhs  ) 

assignment operator

void parseHeader_ ( const String header,
RichPeakSpectrum spec 
) [protected]

reads the header information and stores it as metainfo in the spectrum

void store ( const String filename,
const RichPeakMap exp 
) const

Stores a map in a MSPFile file.

Exceptions:
UnableToCreateFile is thrown if the given file could not be created

OpenMS / TOPP release 1.10.0 Documentation generated on Thu Mar 7 2013 09:42:54 using doxygen 1.7.1