]> git.donarmstrong.com Git - bamtools.git/blob - src/api/internal/ILocalIODevice_p.h
Cleaned up intra-API includes & moved version numbers to 2.0.0
[bamtools.git] / src / api / internal / ILocalIODevice_p.h
1 // ***************************************************************************
2 // ILocalIODevice_p.h (c) 2011 Derek Barnett
3 // Marth Lab, Department of Biology, Boston College
4 // ---------------------------------------------------------------------------
5 // Last modified: 10 October 2011 (DB)
6 // ---------------------------------------------------------------------------
7 // Provides shared behavior for files & pipes
8 // ***************************************************************************
9
10 #ifndef ILOCALIODEVICE_P_H
11 #define ILOCALIODEVICE_P_H
12
13 //  -------------
14 //  W A R N I N G
15 //  -------------
16 //
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.
20 //
21 // We mean it.
22
23 #include "api/IBamIODevice.h"
24
25 namespace BamTools {
26 namespace Internal {
27
28 class ILocalIODevice : public IBamIODevice {
29
30     // ctor & dtor
31     public:
32         ILocalIODevice(void);
33         virtual ~ILocalIODevice(void);
34
35     // IBamIODevice implementation
36     public:
37         virtual void Close(void);
38         virtual size_t Read(char* data, const unsigned int numBytes);
39         virtual int64_t Tell(void) const;
40         virtual size_t Write(const char* data, const unsigned int numBytes);
41
42     // data members
43     protected:
44         FILE* m_stream;
45 };
46
47 } // namespace Internal
48 } // namespace BamTools
49
50 #endif // ILOCALIODEVICE_P_H