Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages

Gradient Class Reference
[Metadata]

#include <OpenMS/METADATA/Gradient.h>

List of all members.


Detailed Description

Representation of a HPLC gradient.

It consists of several eluents and timepoints. Linear behaviour between timepoints is assumed.

Public Member Functions

 Gradient ()
 Constructor.
 Gradient (const Gradient &source)
 Copy constructor.
 ~Gradient ()
 Destructor.
Gradientoperator= (const Gradient &source)
 Assignment operator.
bool operator== (const Gradient &source) const
 Equality operator.
bool operator!= (const Gradient &source) const
 Equality operator.
void addEluent (const String &eluent) throw (Exception::InvalidValue)
 Adds an eluent at the end of the eluent array.
void clearEluents ()
 removes all eluents
const std::vector< String > & getEluents () const
 returns a const reference to the list of eluents
void addTimepoint (Int timepoint) throw (Exception::OutOfRange)
 Adds a timepoint at the end of the timepoint array.
void clearTimepoints ()
 removes all timepoints
const std::vector< Int > & getTimepoints () const
 returns a const reference to the list of timepoints
void setPercentage (const String &eluent, Int timepoint, UInt percentage) throw (Exception::InvalidValue)
 sets the percentage of eluent eluent at timepoint timepoint
const std::vector< std::vector
< UInt > > & 
getPercentages () const
 returns a const reference to the percentages
UInt getPercentage (const String &eluent, Int timepoint) const throw (Exception::InvalidValue)
 returns the percentage of an eluent at a timepoint
void clearPercentages ()
 sets all precentage values to 0
bool isValid () const
 checks if the percentages of all timepoints add up to 100%

Protected Attributes

std::vector< Stringeluents_
std::vector< Inttimes_
std::vector< std::vector< UInt > > percentages_


Constructor & Destructor Documentation

Gradient (  ) 

Constructor.

Gradient ( const Gradient source  ) 

Copy constructor.

~Gradient (  ) 

Destructor.


Member Function Documentation

Gradient& operator= ( const Gradient source  ) 

Assignment operator.

bool operator== ( const Gradient source  )  const

Equality operator.

bool operator!= ( const Gradient source  )  const

Equality operator.

void addEluent ( const String eluent  )  throw (Exception::InvalidValue)

Adds an eluent at the end of the eluent array.

The name of the new eluent has to be different from already present eluents names. Otherwise a InvalidValue exception is thrown.

void clearEluents (  ) 

removes all eluents

const std::vector<String>& getEluents (  )  const

returns a const reference to the list of eluents

void addTimepoint ( Int  timepoint  )  throw (Exception::OutOfRange)

Adds a timepoint at the end of the timepoint array.

The new timpoint has to be after the last timepoint. Otherwise a OutOfRange exception is thrown.

void clearTimepoints (  ) 

removes all timepoints

const std::vector<Int>& getTimepoints (  )  const

returns a const reference to the list of timepoints

void setPercentage ( const String eluent,
Int  timepoint,
UInt  percentage 
) throw (Exception::InvalidValue)

sets the percentage of eluent eluent at timepoint timepoint

const std::vector< std::vector< UInt > >& getPercentages (  )  const

returns a const reference to the percentages

First dimension of the vector is the eluents, second dimension is the timepoints.

UInt getPercentage ( const String eluent,
Int  timepoint 
) const throw (Exception::InvalidValue)

returns the percentage of an eluent at a timepoint

void clearPercentages (  ) 

sets all precentage values to 0

bool isValid (  )  const

checks if the percentages of all timepoints add up to 100%


Member Data Documentation

std::vector<String> eluents_ [protected]

std::vector<Int> times_ [protected]

std::vector< std::vector< UInt > > percentages_ [protected]


The documentation for this class was generated from the following file:
Generated Tue Apr 1 15:36:46 2008 -- using doxygen 1.5.4 OpenMS / TOPP 1.1