-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAlignmentTrack.H
52 lines (46 loc) · 1.47 KB
/
AlignmentTrack.H
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/***********************************************************************
AlignmentTrack.H
BOOM : Bioinformatics Object Oriented Modules
Copyright (C)2012 William H. Majoros ([email protected]).
This is OPEN SOURCE SOFTWARE governed by the Gnu General Public
License (GPL) version 3, as described at www.opensource.org.
***********************************************************************/
#ifndef INCL_AlignmentTrack_H
#define INCL_AlignmentTrack_H
#include "String.H"
namespace BOOM {
class AlignmentTrack
{
public:
AlignmentTrack(const BOOM::String &name,int ID);
const BOOM::String &getName() const;
void setName(const BOOM::String &n) {name=n;}
void rename(const BOOM::String &n) {name=n;}
int getID() const;
void setID(int id) {ID=id;}
int getBegin() const; // relative to source genome, not to alignment!
int getLength() const;
int getNonGapLength() const; // number of non-gap entries in track
void addHSP(int begin,const BOOM::String &seqStr);
void extendToLength(int length);
const BOOM::String &getSeq() const;
inline char &operator[](int);
void deleteSequence();
void setTarget();
bool isTarget() const;
void append(const AlignmentTrack &);
void toupper();
int mapUngappedCoordToGapped(int ungappedCoord);
private:
BOOM::String name;
int begin; // relative to source genome, not to alignment!
BOOM::String seqStr;
bool isTargetTrack;
int ID;
};
char &AlignmentTrack::operator[](int index)
{
return seqStr[index];
}
}
#endif