Diffstat (limited to 'libopie2/opiepim/core/opimaccesstemplate.h') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libopie2/opiepim/core/opimaccesstemplate.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/libopie2/opiepim/core/opimaccesstemplate.h b/libopie2/opiepim/core/opimaccesstemplate.h index 6a3a0db..8ff205c 100644 --- a/libopie2/opiepim/core/opimaccesstemplate.h +++ b/libopie2/opiepim/core/opimaccesstemplate.h | |||
@@ -60,24 +60,30 @@ public: | |||
60 | /** | 60 | /** |
61 | * if the resource was changed externally | 61 | * if the resource was changed externally |
62 | * You should use the signal handling instead of polling possible changes ! | 62 | * You should use the signal handling instead of polling possible changes ! |
63 | * zecke: Do you implement a signal for otodoaccess ? | 63 | * zecke: Do you implement a signal for otodoaccess ? |
64 | */ | 64 | */ |
65 | bool wasChangedExternally()const; | 65 | bool wasChangedExternally()const; |
66 | 66 | ||
67 | /** | 67 | /** |
68 | * return a List of records | 68 | * return a List of records |
69 | * you can iterate over them | 69 | * you can iterate over them |
70 | */ | 70 | */ |
71 | virtual List allRecords()const; | 71 | virtual List allRecords()const; |
72 | |||
73 | /** | ||
74 | * return a List of records | ||
75 | * that match the regex | ||
76 | */ | ||
77 | virtual List matchRegexp( const QRegExp &r ) const; | ||
72 | 78 | ||
73 | /** | 79 | /** |
74 | * queryByExample. | 80 | * queryByExample. |
75 | * @see otodoaccess, ocontactaccess | 81 | * @see otodoaccess, ocontactaccess |
76 | */ | 82 | */ |
77 | virtual List queryByExample( const T& t, int querySettings, const QDateTime& d = QDateTime() ); | 83 | virtual List queryByExample( const T& t, int querySettings, const QDateTime& d = QDateTime() ); |
78 | 84 | ||
79 | /** | 85 | /** |
80 | * find the OPimRecord uid | 86 | * find the OPimRecord uid |
81 | */ | 87 | */ |
82 | virtual T find( int uid )const; | 88 | virtual T find( int uid )const; |
83 | 89 | ||
@@ -172,24 +178,30 @@ bool OPimAccessTemplate<T>::reload() { | |||
172 | } | 178 | } |
173 | template <class T> | 179 | template <class T> |
174 | bool OPimAccessTemplate<T>::save() { | 180 | bool OPimAccessTemplate<T>::save() { |
175 | return m_backEnd->save(); | 181 | return m_backEnd->save(); |
176 | } | 182 | } |
177 | template <class T> | 183 | template <class T> |
178 | typename OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { | 184 | typename OPimAccessTemplate<T>::List OPimAccessTemplate<T>::allRecords()const { |
179 | QArray<int> ints = m_backEnd->allRecords(); | 185 | QArray<int> ints = m_backEnd->allRecords(); |
180 | List lis(ints, this ); | 186 | List lis(ints, this ); |
181 | return lis; | 187 | return lis; |
182 | } | 188 | } |
183 | template <class T> | 189 | template <class T> |
190 | typename OPimAccessTemplate<T>::List OPimAccessTemplate<T>::matchRegexp( const QRegExp &r )const { | ||
191 | QArray<int> ints = m_backEnd->matchRegexp( r ); | ||
192 | List lis(ints, this ); | ||
193 | return lis; | ||
194 | } | ||
195 | template <class T> | ||
184 | QArray<int> OPimAccessTemplate<T>::records()const { | 196 | QArray<int> OPimAccessTemplate<T>::records()const { |
185 | return m_backEnd->allRecords(); | 197 | return m_backEnd->allRecords(); |
186 | } | 198 | } |
187 | template <class T> | 199 | template <class T> |
188 | typename OPimAccessTemplate<T>::List | 200 | typename OPimAccessTemplate<T>::List |
189 | OPimAccessTemplate<T>::queryByExample( const T& t, int settings, const QDateTime& d ) { | 201 | OPimAccessTemplate<T>::queryByExample( const T& t, int settings, const QDateTime& d ) { |
190 | QArray<int> ints = m_backEnd->queryByExample( t, settings, d ); | 202 | QArray<int> ints = m_backEnd->queryByExample( t, settings, d ); |
191 | 203 | ||
192 | List lis(ints, this ); | 204 | List lis(ints, this ); |
193 | return lis; | 205 | return lis; |
194 | } | 206 | } |
195 | template <class T> | 207 | template <class T> |