]> git.donarmstrong.com Git - bamtools.git/blobdiff - src/api/BamWriter.h
Update to BamTools API 0.9.2 with exposure of SamHeader object from BamReader and...
[bamtools.git] / src / api / BamWriter.h
index 55f86f4f29f13b0415604b7f1c785d525239c487..2d8b52810da74764b6e1844d1dced2a93f5dd938 100644 (file)
@@ -3,7 +3,7 @@
 // Marth Lab, Department of Biology, Boston College\r
 // All rights reserved.\r
 // ---------------------------------------------------------------------------\r
-// Last modified: 19 November 2010 (DB)\r
+// Last modified: 11 January 2011 (DB)\r
 // ---------------------------------------------------------------------------\r
 // Provides the basic functionality for producing BAM files\r
 // ***************************************************************************\r
@@ -13,6 +13,7 @@
 \r
 #include <api/api_global.h>\r
 #include <api/BamAlignment.h>\r
+#include <api/SamHeader.h>\r
 #include <string>\r
 \r
 namespace BamTools {\r
@@ -32,11 +33,16 @@ class API_EXPORT BamWriter {
     public:\r
         // closes the alignment archive\r
         void Close(void);\r
-        // opens the alignment archive\r
+        // opens the alignment archive (using std::string SAM header)\r
         bool Open(const std::string& filename, \r
                   const std::string& samHeader, \r
                   const BamTools::RefVector& referenceSequences, \r
                   bool writeUncompressed = false);\r
+        // opens the alignment archive (using SamHeader object)\r
+        bool Open(const std::string& filename,\r
+                  const SamHeader& samHeader,\r
+                  const BamTools::RefVector& referenceSequences,\r
+                  bool writeUncompressed = false);\r
         // saves the alignment to the alignment archive\r
         void SaveAlignment(const BamTools::BamAlignment& al);\r
 \r