Home  · Classes  · Annotated Classes  · Modules  · Members  · Namespaces  · Related Pages
Public Member Functions | List of all members
SuffixArray Class Referenceabstract

abstract class for suffix array More...

#include <OpenMS/DATASTRUCTURES/SuffixArray.h>

Inheritance diagram for SuffixArray:
SuffixArraySeqan SuffixArrayTrypticCompressed SuffixArrayTrypticSeqan

Public Member Functions

 SuffixArray (const String &st, const String &filename)
 constructor taking the string and the filename for writing or reading More...
 
 SuffixArray (const SuffixArray &sa)
 copy constructor More...
 
virtual ~SuffixArray ()=0
 destructor More...
 
virtual String toString ()=0
 transforms suffix array to a printable String More...
 
virtual void findSpec (std::vector< std::vector< std::pair< std::pair< SignedSize, SignedSize >, double > > > &candidates, const std::vector< double > &spec)=0
 the function that will find all peptide candidates for a given spectrum More...
 
virtual bool save (const String &filename)=0
 saves the suffix array to disc More...
 
virtual bool open (const String &filename)=0
 opens the suffix array More...
 
virtual void setTolerance (double t)=0
 setter for tolerance More...
 
virtual double getTolerance () const =0
 getter for tolerance More...
 
virtual bool isDigestingEnd (const char aa1, const char aa2) const =0
 returns if an enzyme will cut after first character More...
 
virtual void setTags (const std::vector< String > &tags)=0
 setter for tags More...
 
virtual const std::vector< String > & getTags ()=0
 getter for tags More...
 
virtual void setUseTags (bool use_tags)=0
 setter for use_tags More...
 
virtual bool getUseTags ()=0
 getter for use_tags More...
 
virtual void setNumberOfModifications (Size number_of_mods)=0
 setter for number of modifications More...
 
virtual Size getNumberOfModifications ()=0
 getter for number of modifications More...
 
virtual void printStatistic ()=0
 output for statistic More...
 
 SuffixArray ()
 constructor More...
 

Detailed Description

abstract class for suffix array

Constructor & Destructor Documentation

SuffixArray ( const String st,
const String filename 
)

constructor taking the string and the filename for writing or reading

Parameters
stthe string as const reference with which the suffix array will be build
filenamethe filename for writing or reading the suffix array
Exceptions
Exception::InvalidValueif string does not start with empty string ($)
Exception::FileNotFoundis thrown if the given filename is not found
SuffixArray ( const SuffixArray sa)

copy constructor

virtual ~SuffixArray ( )
pure virtual

destructor

constructor

Member Function Documentation

virtual void findSpec ( std::vector< std::vector< std::pair< std::pair< SignedSize, SignedSize >, double > > > &  candidates,
const std::vector< double > &  spec 
)
pure virtual

the function that will find all peptide candidates for a given spectrum

Parameters
specconst reference of double vector describing the spectrum
candidatesthe candidates which are returned for the masses given in spec
Returns
a vector of SignedSize pairs.
Exceptions
InvalidValueif the spectrum is not sorted ascendingly

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual Size getNumberOfModifications ( )
pure virtual

getter for number of modifications

Returns
Size describing number of modifications

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual const std::vector<String>& getTags ( )
pure virtual

getter for tags

Returns
const vector of string with tags

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual double getTolerance ( ) const
pure virtual

getter for tolerance

Returns
double with tolerance

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual bool getUseTags ( )
pure virtual

getter for use_tags

Returns
bool indicating whether tags are used or not

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual bool isDigestingEnd ( const char  aa1,
const char  aa2 
) const
pure virtual

returns if an enzyme will cut after first character

Parameters
aa1const char as first aminoacid
aa2const char as second aminoacid
Returns
bool describing if it is a digesting site

Implemented in SuffixArraySeqan, SuffixArrayTrypticCompressed, and SuffixArrayTrypticSeqan.

virtual bool open ( const String filename)
pure virtual

opens the suffix array

Parameters
filenameconst reference string describing the filename
Returns
bool if operation was successful
Exceptions
FileNotFound

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual void printStatistic ( )
pure virtual

output for statistic

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual bool save ( const String filename)
pure virtual

saves the suffix array to disc

Parameters
filenameconst reference string describing the filename
Returns
bool if operation was successful
Exceptions
UnableToCreateFileif file could not be created (e.g. if you have no rights)

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual void setNumberOfModifications ( Size  number_of_mods)
pure virtual

setter for number of modifications

Parameters
number_of_mods

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual void setTags ( const std::vector< String > &  tags)
pure virtual

setter for tags

Parameters
tagsconst vector of strings with tags with length 3 each
Exceptions
Exception::InvalidValueif at least one tag does not have size of 3

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual void setTolerance ( double  t)
pure virtual

setter for tolerance

Parameters
tdouble with tolerance
Exceptions
InvalidValueif tolerance is negative

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual void setUseTags ( bool  use_tags)
pure virtual

setter for use_tags

Parameters
use_tagsindicating whether tags should be used or not

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.

virtual String toString ( )
pure virtual

transforms suffix array to a printable String

Implemented in SuffixArraySeqan, and SuffixArrayTrypticCompressed.


OpenMS / TOPP release 2.0.0 Documentation generated on Tue Nov 1 2016 16:34:46 using doxygen 1.8.11