seqinfo.h

Go to the documentation of this file.
00001 //file:seqinfo.h for use by feature1.h and gbhead.h
00002 #ifndef SEQINFO_H
00003 #define SEQINFO_H
00004 #include <set>
00005 //#include <vector>
00006 #include <string>
00007 #include "strformat.h"
00008 
00009 /* should have just one count for all subsequences */
00010 struct seqinfo {
00011    const char* name() const {return acc;}
00012    //for GB sequences their key name is represented by acc
00013    char type[20]; //such as ss-RNA, mRNA, DNA,  etc.  
00014         bool linear;
00015    char acc[20];
00016    char org[60];
00017    char locus[17];  // is getting longer!
00018         char seg[12];
00019    char div[4];
00020    int len;
00021         int cdsCount;   // count CDS subsequences
00022         int sourCount;  // source sequence count
00023         int mrnaCount;  // count mRNA subsequences
00024         int rnaCount;
00025         int rptCount; //repeat_region count
00026         int tokCount;
00027         int subcnt;  // count all subsequences, safer and faster; all the
00028         // other counts can be removed in the future
00029 
00030         seqinfo();
00031         bool isseg() const {return seg[0] != '\0';}
00032         void nameseg(char sgn[]) const; //obtain a name for the segseq
00033         //based on locus name
00034         //vector<string> sk; //all subkeys for this sequence
00035         set<string> sk; //all subkeys for this sequence
00036         //sometimes subkey generated may have the same name
00037         
00038         // helper function
00039         void getcntstr(char cntstr[]) { itoa(subcnt++, cntstr); }
00040 
00041         /* get count as string */
00042         string getcntstr();
00043 };
00044 
00045 #endif
00046 

Generated on Wed Oct 14 21:49:16 2009 for Softwares from Orpara by  doxygen 1.5.6