aboutsummaryrefslogtreecommitdiff
path: root/src/db.hh
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2003-05-26 13:45:00 +0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2003-05-26 13:45:00 +0000
commit8b930a0c94ba9013d015c735cfc38c40b151f491 (patch)
tree8282adb5a10d18b696ba9c5f81230fc5b5831c94 /src/db.hh
parentf8d91f20e6c88510282263715a1b87c99afad5a1 (diff)
* Some refactoring.
Diffstat (limited to 'src/db.hh')
-rw-r--r--src/db.hh26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/db.hh b/src/db.hh
new file mode 100644
index 000000000..0054dbec1
--- /dev/null
+++ b/src/db.hh
@@ -0,0 +1,26 @@
+#ifndef __DB_H
+#define __DB_H
+
+#include <string>
+#include <list>
+
+using namespace std;
+
+typedef pair<string, string> DBPair;
+typedef list<DBPair> DBPairs;
+
+void createDB(const string & filename, const string & dbname);
+
+bool queryDB(const string & filename, const string & dbname,
+ const string & key, string & data);
+
+void setDB(const string & filename, const string & dbname,
+ const string & key, const string & data);
+
+void delDB(const string & filename, const string & dbname,
+ const string & key);
+
+void enumDB(const string & filename, const string & dbname,
+ DBPairs & contents);
+
+#endif /* !__DB_H */