afbb9da21e65c1454b9d299b19380d119b6e27f5
[mussa.git] / sequence.hh
1 //                        ----------------------------------------
2 //                           ---------- sequence.hh -----------
3 //                        ----------------------------------------
4
5
6 #include <iostream>
7 #include <list>
8 #include <vector>
9 #include <string>
10 #include <fstream.h>
11 #include <stdlib.h>
12 #include <algorithm>
13
14 // Sequence data class
15
16 class Sequence
17 {
18   friend class ConnView;
19   friend class SeqView;
20   private:
21     string sequence;
22     int length;
23     string header;
24     string species;
25     int species_num; 
26
27     struct annot
28     {
29       int start, end;
30       string name, type;
31     };
32
33     list<annot> annots;
34
35
36
37
38   public:
39     Sequence();
40     void load_fasta(string file_path, int seq_num);
41     void load_annot(string file_path);
42     string seq();
43     const char * c_seq();
44     string rev_comp();
45     int len();
46     string hdr();
47     void set_seq(string a_seq);
48   //  string species();
49     void clear();
50 };