]> git.donarmstrong.com Git - mothur.git/blob - alignment.hpp
Revert to previous commit
[mothur.git] / alignment.hpp
1 #ifndef DPALIGNMENT_H
2 #define DPALIGNMENT_H
3
4 /*
5  *  dpalignment.h
6  *  
7  *
8  *  Created by Pat Schloss on 12/15/08.
9  *  Copyright 2008 Patrick D. Schloss. All rights reserved.
10  *
11  *  This is a class for an abstract datatype for classes that implement various types of alignment      algorithms.
12  *      As of 12/18/08 these included alignments based on blastn, needleman-wunsch, and the     Gotoh algorithms
13  * 
14  */
15
16 #include "mothur.h"
17 #include "alignmentcell.hpp"
18
19 /**************************************************************************************************/
20
21 class Alignment {
22         
23 public:
24         Alignment(int);
25         Alignment();
26         virtual ~Alignment();
27         virtual void align(string, string) = 0;
28         
29         
30 //      float getAlignmentScore();
31         string getSeqAAln();
32         string getSeqBAln();
33         int getCandidateStartPos();
34         int getCandidateEndPos();
35         int getTemplateStartPos();
36         int getTemplateEndPos();
37         
38         int getPairwiseLength();
39         void resize(int);
40         int getnRows() { return nRows; }
41 //      int getLongestTemplateGap();
42
43 protected:
44         void traceBack();
45         string seqA, seqAaln;
46         string seqB, seqBaln;
47         int seqAstart, seqAend;
48         int seqBstart, seqBend;
49         int pairwiseLength;
50         int nRows, nCols, lA, lB;
51         vector<vector<AlignmentCell> > alignment;
52         MothurOut* m;
53 };
54
55 /**************************************************************************************************/
56
57 #endif