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

FastaIteratorIntern Class Reference

#include <OpenMS/FORMAT/FastaIteratorIntern.h>

Inheritance diagram for FastaIteratorIntern:

PepIterator FactoryProduct

List of all members.


Detailed Description

Iterator for a FASTA file.

In comparision to FastaIterator the FASTA file will be loaded first and stored to RAM, while the FastaIterator just iterates over the FASTA file without loading it completly to memory.

See also:
FastaIterator

Public Types

typedef std::pair< String, StringFASTAEntry

Public Member Functions

 FastaIteratorIntern ()
 constructor
 FastaIteratorIntern (const FastaIteratorIntern &)
 copy constructor
virtual ~FastaIteratorIntern ()
 constructor
virtual FASTAEntry operator * () throw (Exception::InvalidIterator)
 * Operator for derefering of iterator
virtual PepIteratoroperator++ () throw (Exception::InvalidIterator)
 ++ Operator for the iterator
virtual PepIteratoroperator++ (int i) throw (Exception::InvalidIterator)
 ++ Operator for the iterator
virtual void setFastaFile (const String &f) throw (Exception::FileNotFound,Exception::ParseError)
 setter for FASTA file
virtual String getFastaFile ()
 getter for FASTA file
virtual void setSpectrum (const std::vector< float > &) throw (Exception::NotImplemented)
 setter for spectrum
virtual const std::vector
< float > & 
getSpectrum () throw (Exception::NotImplemented)
 getter for spectrum
virtual void setTolerance (float) throw (Exception::NotImplemented)
 setter for tolerance
virtual float getTolerance () throw (Exception::NotImplemented)
 getter for tolerance
virtual bool begin () throw (Exception::InvalidIterator)
 initializing of iterator
virtual bool isAtEnd ()
 indicates whether iterator is at end

Static Public Member Functions

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

Protected Attributes

String fasta_file_
 location of the fasta file
std::vector< FASTAEntryentrys_
 content of fasta file
std::vector< FASTAEntry >::iterator it_
 iterator over fasta file content

Member Typedef Documentation

typedef std::pair<String,String> FASTAEntry

Reimplemented from PepIterator.


Constructor & Destructor Documentation

FastaIteratorIntern (  ) 

constructor

FastaIteratorIntern ( const FastaIteratorIntern  ) 

copy constructor

virtual ~FastaIteratorIntern (  )  [virtual]

constructor


Member Function Documentation

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

* Operator for derefering of iterator

Returns:
FASTEEntry iterator at actual position
Exceptions:
Exception::InvalidIterator if iterator has not been initialized

Implements PepIterator.

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

++ Operator for the iterator

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

Implements PepIterator.

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

++ Operator for the iterator

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

Implements PepIterator.

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

setter for FASTA file

Parameters:
f const String reference representing file location
Exceptions:
Exception::FileNotFound 
Exception::ParseError 

Implements PepIterator.

virtual String getFastaFile (  )  [virtual]

getter for FASTA file

Returns:
String with file location

Implements PepIterator.

virtual void setSpectrum ( const std::vector< float > &   )  throw (Exception::NotImplemented) [inline, virtual]

setter for spectrum

Note:
note availeble for FastaIterator
Exceptions:
Exception::NotImplemented 

Implements PepIterator.

virtual const std::vector<float>& getSpectrum (  )  throw (Exception::NotImplemented) [inline, virtual]

getter for spectrum

Note:
note availeble for FastaIterator
Exceptions:
Exception::NotImplemented 

Implements PepIterator.

virtual void setTolerance ( float   )  throw (Exception::NotImplemented) [inline, virtual]

setter for tolerance

Note:
note availeble for FastaIterator
Parameters:
t tolerance value
Exceptions:
Exception::NotImplemented 

Implements PepIterator.

virtual float getTolerance (  )  throw (Exception::NotImplemented) [inline, virtual]

getter for tolerance

Note:
note availeble for FastaIterator
Returns:
tolerance
Exceptions:
Exception::NotImplemented 

Implements PepIterator.

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

initializing of iterator

Returns:
true if everything went rigth
Exceptions:
Exception::InvalidIterator if fastaFile was not set

Implements PepIterator.

virtual bool isAtEnd (  )  [virtual]

indicates whether iterator is at end

Returns:
bool true if interator is at end

Implements PepIterator.

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

needed by FactoryProduct

Returns:
const string name of class

static PepIterator* create (  )  [inline, static]

needed by FactoryProduct

Returns:
poiter to new object


Member Data Documentation

String fasta_file_ [protected]

location of the fasta file

std::vector<FASTAEntry > entrys_ [protected]

content of fasta file

std::vector<FASTAEntry >::iterator it_ [protected]

iterator over fasta file content


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