]> git.donarmstrong.com Git - bamtools.git/blobdiff - src/api/internal/BamHttp_p.cpp
Basic internal implementation of BamFile & BamPipe
[bamtools.git] / src / api / internal / BamHttp_p.cpp
diff --git a/src/api/internal/BamHttp_p.cpp b/src/api/internal/BamHttp_p.cpp
new file mode 100644 (file)
index 0000000..532194b
--- /dev/null
@@ -0,0 +1,56 @@
+// ***************************************************************************
+// BamHttp_p.cpp (c) 2011 Derek Barnett
+// Marth Lab, Department of Biology, Boston College
+// ---------------------------------------------------------------------------
+// Last modified: 9 September 2011 (DB)
+// ---------------------------------------------------------------------------
+// Provides reading/writing of BAM files on HTTP server
+// ***************************************************************************
+
+#include <api/internal/BamHttp_p.h>
+using namespace BamTools;
+using namespace BamTools::Internal;
+
+using namespace std;
+
+BamHttp::BamHttp(const string& url)
+    : IBamIODevice()
+{
+    BT_ASSERT_X(false, "BamHttp not yet implemented");
+}
+
+BamHttp::~BamHttp(void) { }
+
+void BamHttp::Close(void) {
+    return ;
+}
+
+bool BamHttp::IsRandomAccess(void) const {
+    return true;
+}
+
+bool BamHttp::Open(const IBamIODevice::OpenMode mode) {
+    (void) mode;
+    return true;
+}
+
+size_t BamHttp::Read(char* data, const unsigned int numBytes) {
+    (void)data;
+    (void)numBytes;
+    return 0;
+}
+
+bool BamHttp::Seek(const int64_t& position) {
+    (void)position;
+    return true;
+}
+
+int64_t BamHttp::Tell(void) const {
+    return -1;
+}
+
+size_t BamHttp::Write(const char* data, const unsigned int numBytes) {
+    (void)data;
+    (void)numBytes;
+    return 0;
+}