Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Public Types | Public Member Functions | Private Attributes

WeightWrapper Class Reference

Encapsulated weight queries to simplify mono vs average weight computation. More...

#include <OpenMS/CHEMISTRY/WeightWrapper.h>

Inheritance diagram for WeightWrapper:
SuffixArrayPeptideFinder SuffixArraySeqan SuffixArrayTrypticCompressed SuffixArrayTrypticSeqan

List of all members.

Public Types

enum  WEIGHTMODE { AVERAGE = 0, MONO, SIZE_OF_WEIGHTMODE }

Public Member Functions

 WeightWrapper ()
 constructor
 WeightWrapper (const WEIGHTMODE weight_mode)
 constructor
virtual ~WeightWrapper ()
 destructor
 WeightWrapper (const WeightWrapper &source)
 copy constructor
void setWeightMode (const WEIGHTMODE mode)
 Sets the weight mode (MONO or AVERAGE).
WEIGHTMODE getWeightMode () const
 Gets the weight mode (MONO or AVERAGE).
DoubleReal getWeight (const AASequence &aa) const
 returns the weight of either mono or average value
DoubleReal getWeight (const EmpiricalFormula &ef) const
 returns the weight of either mono or average value
DoubleReal getWeight (const Residue &r, Residue::ResidueType res_type=Residue::Full) const
 returns the weight of either mono or average value

Private Attributes

WEIGHTMODE weight_mode_
 one of WeightWrapper::WEIGHTMODE's values

Detailed Description

Encapsulated weight queries to simplify mono vs average weight computation.

Supports EmpiricalFormula's and AASequence's getMonoWeight() and getAverageWeight()


Member Enumeration Documentation

enum WEIGHTMODE
Enumerator:
AVERAGE 
MONO 
SIZE_OF_WEIGHTMODE 

Constructor & Destructor Documentation

WeightWrapper (  ) 

constructor

WeightWrapper ( const WEIGHTMODE  weight_mode  ) 

constructor

virtual ~WeightWrapper (  )  [virtual]

destructor

WeightWrapper ( const WeightWrapper source  ) 

copy constructor


Member Function Documentation

DoubleReal getWeight ( const AASequence aa  )  const

returns the weight of either mono or average value

Which weight is returned depends on the current weight-mode.

Returns:
DoubleReal weight in u
DoubleReal getWeight ( const Residue r,
Residue::ResidueType  res_type = Residue::Full 
) const

returns the weight of either mono or average value

Which weight is returned depends on the current weight-mode.

Returns:
DoubleReal weight in u
DoubleReal getWeight ( const EmpiricalFormula ef  )  const

returns the weight of either mono or average value

Which weight is returned depends on the current weight-mode.

Returns:
DoubleReal weight in u
WEIGHTMODE getWeightMode (  )  const

Gets the weight mode (MONO or AVERAGE).

Gets the mode in which getWeight() calls are answered.

void setWeightMode ( const WEIGHTMODE  mode  ) 

Sets the weight mode (MONO or AVERAGE).

Sets the mode in which getWeight() calls are answered.


Member Data Documentation


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