]> git.donarmstrong.com Git - bamtools.git/blobdiff - src/api/BamMultiReader.h
Cleaned up intra-API includes & moved version numbers to 2.0.0
[bamtools.git] / src / api / BamMultiReader.h
index 43ef56a86c6d0a8cfead8ba12155443ab1e7ee76..76d0810e2f6fa411b5cf00e80426304292c03d69 100644 (file)
@@ -1,9 +1,8 @@
 // ***************************************************************************
 // BamMultiReader.h (c) 2010 Erik Garrison, Derek Barnett
 // Marth Lab, Department of Biology, Boston College
-// All rights reserved.
 // ---------------------------------------------------------------------------
-// Last modified: 1 October 2011 (DB)
+// Last modified: 10 October 2011 (DB)
 // ---------------------------------------------------------------------------
 // Convenience class for reading multiple BAM files.
 // ***************************************************************************
@@ -11,8 +10,8 @@
 #ifndef BAMMULTIREADER_H
 #define BAMMULTIREADER_H
 
-#include <api/api_global.h>
-#include <api/BamReader.h>
+#include "api/api_global.h"
+#include "api/BamReader.h"
 #include <map>
 #include <sstream>
 #include <string>
@@ -39,9 +38,9 @@ class API_EXPORT BamMultiReader {
         // ----------------------
 
         // closes all open BAM files
-        void Close(void);
+        bool Close(void);
         // close only the requested BAM file
-        void CloseFile(const std::string& filename);
+        bool CloseFile(const std::string& filename);
         // returns list of filenames for all open BAM files
         const std::vector<std::string> Filenames(void) const;
         // returns true if multireader has any open BAM files
@@ -101,6 +100,13 @@ class API_EXPORT BamMultiReader {
         // changes the caching behavior of the index data
         void SetIndexCacheMode(const BamIndex::IndexCacheMode& mode);
 
+        // ----------------------
+        // error handling
+        // ----------------------
+
+        // returns a human-readable description of the last error that occurred
+        std::string GetErrorString(void) const;
+
     // private implementation
     private:
         Internal::BamMultiReaderPrivate* d;