1 // ***************************************************************************
2 // SamFormatPrinter.h (c) 2010 Derek Barnett
3 // Marth Lab, Department of Biology, Boston College
4 // ---------------------------------------------------------------------------
5 // Last modified: 6 October 2011 (DB)
6 // ---------------------------------------------------------------------------
7 // Provides functionality for printing formatted SAM header to string
8 // ***************************************************************************
10 #ifndef SAM_FORMAT_PRINTER_H
11 #define SAM_FORMAT_PRINTER_H
17 // This file is not part of the BamTools API. It exists purely as an
18 // implementation detail. This header file may change from version to version
19 // without notice, or even be removed.
32 class SamFormatPrinter {
36 SamFormatPrinter(const BamTools::SamHeader& header);
37 ~SamFormatPrinter(void);
39 // generates SAM-formatted string from header data
41 const std::string ToString(void) const;
45 void PrintHD(std::stringstream& out) const;
46 void PrintSQ(std::stringstream& out) const;
47 void PrintRG(std::stringstream& out) const;
48 void PrintPG(std::stringstream& out) const;
49 void PrintCO(std::stringstream& out) const;
53 const SamHeader& m_header;
56 } // namespace Internal
57 } // namespace BamTools
59 #endif // SAM_FORMAT_PRINTER_H