summaryrefslogtreecommitdiff
path: root/src/chunked.hh
diff options
context:
space:
mode:
authorJoel Klinghed <the_jk@yahoo.com>2017-02-28 21:50:44 +0100
committerJoel Klinghed <the_jk@yahoo.com>2017-02-28 21:50:44 +0100
commitc029d90d1975e124d237605f1edb2be16bd05b5d (patch)
tree9df87ffb365354bdb74a969440b32c8304bdbcb7 /src/chunked.hh
Initial commit
Diffstat (limited to 'src/chunked.hh')
-rw-r--r--src/chunked.hh23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/chunked.hh b/src/chunked.hh
new file mode 100644
index 0000000..66d3ae7
--- /dev/null
+++ b/src/chunked.hh
@@ -0,0 +1,23 @@
+// -*- mode: c++; c-basic-offset: 2; -*-
+
+#ifndef CHUNKED_HH
+#define CHUNKED_HH
+
+#include <cstddef>
+
+class Chunked {
+public:
+ virtual ~Chunked() { }
+
+ static Chunked* create();
+
+ virtual size_t add(void const* data, size_t avail) = 0;
+ virtual bool good() const = 0;
+ virtual bool eof() const = 0;
+
+protected:
+ Chunked() {}
+ Chunked(Chunked const&) = delete;
+};
+
+#endif // CHUNKED_HH