1 // ***************************************************************************
2 // SamReadGroup.h (c) 2010 Derek Barnett
3 // Marth Lab, Department of Biology, Boston College
4 // All rights reserved.
5 // ---------------------------------------------------------------------------
6 // Last modified: 23 December 2010 (DB)
7 // ---------------------------------------------------------------------------
8 // Provides functionality for querying/manipulating read group data
9 // **************************************************************************
11 #ifndef SAM_READGROUP_H
12 #define SAM_READGROUP_H
14 #include "api/api_global.h"
19 class API_EXPORT SamReadGroup {
24 SamReadGroup(const std::string& id);
25 explicit SamReadGroup(const SamReadGroup& other);
34 // convenience methods to check if SamReadGroup contains these values:
35 bool HasID(void) const;
36 bool HasSample(void) const;
37 bool HasLibrary(void) const;
38 bool HasDescription(void) const;
39 bool HasPlatformUnit(void) const;
40 bool HasPredictedInsertSize(void) const;
41 bool HasSequencingCenter(void) const;
42 bool HasProductionDate(void) const;
43 bool HasSequencingTechnology(void) const;
47 std::string ID; // ID:<ID>
48 std::string Sample; // SM:<Sample>
49 std::string Library; // LB:<Library>
50 std::string Description; // DS:<Description>
51 std::string PlatformUnit; // PU:<PlatformUnit>
52 std::string PredictedInsertSize; // PI:<PredictedInsertSize>
53 std::string SequencingCenter; // CN:<SequencingCenter>
54 std::string ProductionDate; // DT:<ProductionDate>
55 std::string SequencingTechnology; // PL:<SequencingTechnology>
58 // ---------------------------------------------------
59 // comparison operators
61 // for equality: compare IDs
62 inline bool operator==(const SamReadGroup& lhs, const SamReadGroup& rhs) {
63 return lhs.ID == rhs.ID;
66 } // namespace BamTools
68 #endif // SAM_READGROUP_H