summaryrefslogtreecommitdiff
path: root/libopie/pim/otemplatebase.h
Unidiff
Diffstat (limited to 'libopie/pim/otemplatebase.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie/pim/otemplatebase.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/libopie/pim/otemplatebase.h b/libopie/pim/otemplatebase.h
index f71417b..b855919 100644
--- a/libopie/pim/otemplatebase.h
+++ b/libopie/pim/otemplatebase.h
@@ -1,6 +1,8 @@
1#ifndef OPIE_TEMPLATE_BASE_H 1#ifndef OPIE_TEMPLATE_BASE_H
2#define OPIE_TEMPLATE_BASE_H 2#define OPIE_TEMPLATE_BASE_H
3 3
4#include <qarray.h>
5
4#include "opimrecord.h" 6#include "opimrecord.h"
5 7
6/** 8/**
@@ -9,12 +11,21 @@
9template <class T = OPimRecord> 11template <class T = OPimRecord>
10class OTemplateBase { 12class OTemplateBase {
11public: 13public:
14 enum CacheDirection { Forward=0, Reverse };
12 OTemplateBase() { 15 OTemplateBase() {
13 }; 16 };
14 virtual ~OTemplateBase() { 17 virtual ~OTemplateBase() {
15 } 18 }
16 virtual T find( int uid )const = 0; 19 virtual T find( int uid )const = 0;
17 20
21 /**
22 * read ahead find
23 */
24 virtual T find( int uid, const QArray<int>& items,
25 uint current, CacheDirection dir = Forward )const = 0;
26 virtual void cache( const T& )const = 0;
27 virtual void setSaneCacheSize( int ) = 0;
28
18}; 29};
19 30
20 31