summaryrefslogtreecommitdiff
path: root/libopie2/opiepim/backend
Unidiff
Diffstat (limited to 'libopie2/opiepim/backend') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiepim/backend/opimaccessbackend.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/libopie2/opiepim/backend/opimaccessbackend.h b/libopie2/opiepim/backend/opimaccessbackend.h
new file mode 100644
index 0000000..d9af589
--- a/dev/null
+++ b/libopie2/opiepim/backend/opimaccessbackend.h
@@ -0,0 +1,29 @@
1#ifndef OPIE_PIM_ACCESS_BACKEND
2#define OPIE_PIM_ACCESS_BACKEND
3
4#include <qarray.h>
5
6#include <opie/opimrecord.h>
7
8template <class T = OPimRecord>
9class OPimAccessBackend {
10public:
11 OPimAccessBackend() {
12 }
13 ~OPimAccessBackend() {
14 }
15 virtual void load() = 0;
16 virtual void reload() = 0;
17 virtual void save() = 0;
18 virtual QArray<int> allRecords() = 0;
19 virtual QArray<int> queryByExample( const T& t, int sort ) = 0;
20 virtual T find(int uid ) = 0;
21 virtual void clear() = 0;
22 virtual bool add( const T& t ) = 0;
23 virtual bool remove( int uid ) = 0;
24 virtual void replace( const T& t ) = 0;
25
26
27};
28
29#endif