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

EdwardsLippertIterator Class Reference

#include <OpenMS/CHEMISTRY/EdwardsLippertIterator.h>

Inheritance diagram for EdwardsLippertIterator:

PepIterator FactoryProduct EdwardsLippertIteratorTryptic

List of all members.


Detailed Description

finds all Peptide Candidates with given masses and given fasta file

The used algorithm was described by Edwards and Lippert. The algorithm uses two pointers to iterator over a sequence. One pointer represents the start the other the end.

Public Types

typedef std::pair< String, StringFASTAEntry

Public Member Functions

 EdwardsLippertIterator ()
 Constructor.
 EdwardsLippertIterator (const EdwardsLippertIterator &)
 Copy Constructor.
virtual ~EdwardsLippertIterator ()
 Destructor.
virtual FASTAEntry operator * () throw (Exception::InvalidIterator)
 * operator for getting the value of the iterator
virtual PepIteratoroperator++ () throw (Exception::InvalidIterator)
 opperator ++ for postincrement
virtual PepIteratoroperator++ (int i) throw (Exception::InvalidIterator)
 opperator ++ for preincrement
virtual void setFastaFile (const String &f) throw (Exception::FileNotFound)
 setter for fasta file
virtual String getFastaFile ()
 getter for FASTA file
virtual void setTolerance (float t) throw (Exception::InvalidValue)
 setter for tolerance
virtual float getTolerance ()
 getter for tolerance
virtual void setSpectrum (const std::vector< float > &s) throw (Exception::InvalidValue)
 setter for spectrum
virtual const std::vector
< float > & 
getSpectrum ()
 getter for spectrum
virtual bool begin () throw (Exception::InvalidIterator)
 initializing iterator
virtual bool isAtEnd ()
 indicates whether iterator is at end
virtual bool isDigestingEnd (char, char)
 indicated if a digesting enzyme will cut at this position

Static Public Member Functions

static const std::string getName ()
 needed by FactoryProduct
static PepIteratorcreate ()
 needed by FactoryProduct

Protected Member Functions

virtual std::string next_ ()
 getting the next candidate
bool hasNext_ ()
 indicates if there will be a next element
void goToNextAA_ ()
 finds the next starting position where a digesting enzyme will cut the sequence
virtual bool isInSpectrum_ (float &mass)
 indicates if a mass is in spectrum

Protected Attributes

String f_file_
 fasta file location
std::string actual_pep_
 actual peptide
std::vector< float > spec_
 given spectrum
float tol_
 tolerance
float masse_ [255]
 mass table
bool is_at_end_
 indicates if iterator is at end
PepIteratorf_iterator_
 FastaIterator.
FASTAEntry f_entry_
 actual fasta entry
unsigned int b_
unsigned int e_
 to ints representing a position within the actual string (b = begin, e = end)
float m_
float massMax_
 mass and maximum masse


Member Typedef Documentation

typedef std::pair<String,String> FASTAEntry

Reimplemented from PepIterator.


Constructor & Destructor Documentation

EdwardsLippertIterator (  ) 

Constructor.

EdwardsLippertIterator ( const EdwardsLippertIterator  ) 

Copy Constructor.

virtual ~EdwardsLippertIterator (  )  [virtual]

Destructor.


Member Function Documentation

virtual FASTAEntry operator * (  )  throw (Exception::InvalidIterator) [virtual]

* operator for getting the value of the iterator

Returns:
FASTAEntry with specific candidate
Exceptions:
Exception::InvalidIterator if iterator has not been initialized

Implements PepIterator.

virtual PepIterator& operator++ (  )  throw (Exception::InvalidIterator) [virtual]

opperator ++ for postincrement

Returns:
Reference to PepIterator
Exceptions:
Exception::InvalidIterator if iterator has not been initialized

Implements PepIterator.

virtual PepIterator* operator++ ( int  i  )  throw (Exception::InvalidIterator) [virtual]

opperator ++ for preincrement

Returns:
pointer to PepIterator
Exceptions:
Exception::InvalidIterator if iterator has not been initialized

Implements PepIterator.

virtual void setFastaFile ( const String f  )  throw (Exception::FileNotFound) [virtual]

setter for fasta file

Parameters:
f String with fasta file location
Exceptions:
Exception::FileNotFound if file could not be found

Implements PepIterator.

virtual String getFastaFile (  )  [virtual]

getter for FASTA file

Returns:
String with file location

Implements PepIterator.

virtual void setTolerance ( float  t  )  throw (Exception::InvalidValue) [virtual]

setter for tolerance

Parameters:
t tolerance
Exceptions:
Exception::InvalidValue if tolerance is negative

Implements PepIterator.

virtual float getTolerance (  )  [virtual]

getter for tolerance

Returns:
tolerance

Implements PepIterator.

virtual void setSpectrum ( const std::vector< float > &  s  )  throw (Exception::InvalidValue) [virtual]

setter for spectrum

Parameters:
s spectrum as a vector of floats
Exceptions:
Exception::InvalidValue if spectrum is not sorted

Implements PepIterator.

virtual const std::vector<float>& getSpectrum (  )  [virtual]

getter for spectrum

Returns:
the used spectrum

Implements PepIterator.

virtual bool begin (  )  throw (Exception::InvalidIterator) [virtual]

initializing iterator

Returns:
true if everything was ok

Implements PepIterator.

virtual bool isAtEnd (  )  [virtual]

indicates whether iterator is at end

Returns:
true if iterator is at end
See also:
hasNext

Implements PepIterator.

virtual bool isDigestingEnd ( char  ,
char   
) [virtual]

indicated if a digesting enzyme will cut at this position

Returns:
true if digenting enzym cuts the sequence

Reimplemented in EdwardsLippertIteratorTryptic.

static const std::string getName (  )  [inline, static]

needed by FactoryProduct

Returns:
const string name of class

Reimplemented in EdwardsLippertIteratorTryptic.

static PepIterator* create (  )  [inline, static]

needed by FactoryProduct

Returns:
poiter to new object

Reimplemented in EdwardsLippertIteratorTryptic.

virtual std::string next_ (  )  [protected, virtual]

getting the next candidate

Returns:
string with next sequence

bool hasNext_ (  )  [protected]

indicates if there will be a next element

Returns:
true if iterator has more elements

void goToNextAA_ (  )  [protected]

finds the next starting position where a digesting enzyme will cut the sequence

virtual bool isInSpectrum_ ( float &  mass  )  [protected, virtual]

indicates if a mass is in spectrum

Returns:
true if a given mass is in spectrum


Member Data Documentation

String f_file_ [protected]

fasta file location

std::string actual_pep_ [protected]

actual peptide

std::vector<float> spec_ [protected]

given spectrum

float tol_ [protected]

tolerance

float masse_[255] [protected]

mass table

bool is_at_end_ [protected]

indicates if iterator is at end

PepIterator* f_iterator_ [protected]

FastaIterator.

FASTAEntry f_entry_ [protected]

actual fasta entry

unsigned int b_ [protected]

unsigned int e_ [protected]

to ints representing a position within the actual string (b = begin, e = end)

float m_ [protected]

float massMax_ [protected]

mass and maximum masse


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