summaryrefslogtreecommitdiffabout
path: root/src/db.h
Side-by-side diff
Diffstat (limited to 'src/db.h') (more/less context) (show whitespace changes)
-rw-r--r--src/db.h28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/db.h b/src/db.h
new file mode 100644
index 0000000..3794eae
--- a/dev/null
+++ b/src/db.h
@@ -0,0 +1,28 @@
+#ifndef __N_DB_H
+#define __N_DB_H
+
+#include <string>
+#include <list>
+#include <napkin/types.h>
+#include "sqlite.h"
+
+namespace napkin {
+ using std::string;
+ using std::list;
+
+ class db_t : public sqlite::db_t {
+ public:
+ string datadir;
+
+ db_t();
+
+ void store(const hypnodata_t& hd);
+ void remove(const hypnodata_t& hd);
+
+ void load(list<hypnodata_ptr_t>& rv,
+ const string& sql);
+ };
+
+}
+
+#endif /* __N_DB_H */