libStatGen Software  1
PileupElementBaseQual.h
1 /*
2  * Copyright (C) 2010 Regents of the University of Michigan
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef __PILEUP_ELEMENT_BASE_QUAL_H__
19 #define __PILEUP_ELEMENT_BASE_QUAL_H__
20 
21 #include <stdint.h>
22 #include "PileupElement.h"
23 
24 /// This class inherits from the base class and stores base and qualities.
26 {
27 public:
29  // NOTE that this method does not actually copy, it just resets.
31  virtual ~PileupElementBaseQual();
32 
33  // Add an entry to this pileup element.
34  virtual void addEntry(SamRecord& record);
35 
36  // Perform the alalysis associated with this class. In this case, it is
37  // a print of the base & quality information associated with this position.
38  virtual void analyze();
39 
40  // Resets the entry, setting the new position associated with this element.
41  virtual void reset(int32_t refPosition);
42 
43 private:
44  static const char UNSET_QUAL = 0xFF;
45 
46  char* myBases;
47  char* myQualities;
48  int myAllocatedSize;
49  int myIndex;
50  bool myAddDelAsBase;
51 };
52 
53 #endif
This class inherits from the base class and stores base and qualities.
virtual void reset(int32_t refPosition)
Resets the entry, setting the new position associated with this element.
virtual void analyze()
Perform the analysis associated with this class.
virtual void addEntry(SamRecord &record)
Add an entry to this pileup element.
This is a base class pileup component, representing the information for one reference position.
Definition: PileupElement.h:27
Class providing an easy to use interface to get/set/operate on the fields in a SAM/BAM record.
Definition: SamRecord.h:52