tidx.h

filter: Statementstmt 0.0% 0 / 1 Branchbran 0.0% 0 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub n/a Podpod n/a totaltotal 0.0% 0 / 7 CC 0 SCAR 0
CC
0
Cov
0%
CRAP 0
« tidx.cpp ↑ Summary utils.cpp »
1 #include <string>
2 #include <vector>
3 #include <sparsehash/dense_hash_map>
4  
5 class annot {
6 public:
7 int beg;
8 int end;
9 std::vector<long> pos;
10 };
11  
12 class tidx {
13 FILE *fh;
14 void init();
15 public:
16 bool debug;
17 tidx() {init();};
18 0 ▶ tidx(const char *path) {init(); read(path);};
Branch: 3 branches
BranchTrueFalseTotal
tidx(const char *path) {init(); read(path);}; 0 0 0
tidx(const char *path) {init(); read(path);}; 0 0 0
tidx(const char *path) {init(); read(path);}; 0 0 0
19  
20 std::string path;
21 google::dense_hash_map<std::string,std::vector<annot> > map;
22  
23 void dump(FILE *stream);
24 bool read(const char *path);
25 void build(const char *path, const char *sep, int nchr, int nbeg, int nend, int skip_i, char skip_c, bool sub_e);
26  
27 const std::vector <long int> & lookup(const char *chr, int pos);
28 std::string lookup(const char *chr, int pos, const char *msep);
29  
30 // range lookup
31 std::vector <long int> lookup_r(const char *chr, int beg, int end);
32 std::string lookup_r(const char *chr, int beg, int end, const char *msep);
33  
34 // const char * return value
35 const char * lookup_c(const char *chr, int pos, const char *msep);
36 const char * lookup_cr(const char *chr, int beg, int end, const char *msep);
37 };
38  
39 void chomp_line(struct line &l);
40  
41 // build, with no return value, for API use
42 void tidx_build(const char *path, const char *sep, int nchr, int nbeg, int nend, int skip_i, char skip_c, bool sub_e);
43  
« tidx.cpp ↑ Summary utils.cpp »