Diffstat (limited to 'libopie2/opiepim/core/odatebookaccess.h') (more/less context) (show whitespace changes)
-rw-r--r-- | libopie2/opiepim/core/odatebookaccess.h | 33 |
1 files changed, 32 insertions, 1 deletions
diff --git a/libopie2/opiepim/core/odatebookaccess.h b/libopie2/opiepim/core/odatebookaccess.h index 62196da..38dc754 100644 --- a/libopie2/opiepim/core/odatebookaccess.h +++ b/libopie2/opiepim/core/odatebookaccess.h | |||
@@ -1,44 +1,75 @@ | |||
1 | /* | ||
2 | This file is part of the Opie Project | ||
3 | Copyright (C) Stefan Eilers (Eilers.Stefan@epost.de) | ||
4 | =. Copyright (C) The Opie Team <opie-devel@handhelds.org> | ||
5 | .=l. | ||
6 | .>+-= | ||
7 | _;:, .> :=|. This program is free software; you can | ||
8 | .> <`_, > . <= redistribute it and/or modify it under | ||
9 | :`=1 )Y*s>-.-- : the terms of the GNU Library General Public | ||
10 | .="- .-=="i, .._ License as published by the Free Software | ||
11 | - . .-<_> .<> Foundation; either version 2 of the License, | ||
12 | ._= =} : or (at your option) any later version. | ||
13 | .%`+i> _;_. | ||
14 | .i_,=:_. -<s. This program is distributed in the hope that | ||
15 | + . -:. = it will be useful, but WITHOUT ANY WARRANTY; | ||
16 | : .. .:, . . . without even the implied warranty of | ||
17 | =_ + =;=|` MERCHANTABILITY or FITNESS FOR A | ||
18 | _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU | ||
19 | ..}^=.= = ; Library General Public License for more | ||
20 | ++= -. .` .: details. | ||
21 | : = ...= . :.=- | ||
22 | -. .:....=;==+<; You should have received a copy of the GNU | ||
23 | -_. . . )=. = Library General Public License along with | ||
24 | -- :-=` this library; see the file COPYING.LIB. | ||
25 | If not, write to the Free Software Foundation, | ||
26 | Inc., 59 Temple Place - Suite 330, | ||
27 | Boston, MA 02111-1307, USA. | ||
28 | */ | ||
1 | #ifndef OPIE_DATE_BOOK_ACCESS_H | 29 | #ifndef OPIE_DATE_BOOK_ACCESS_H |
2 | #define OPIE_DATE_BOOK_ACCESS_H | 30 | #define OPIE_DATE_BOOK_ACCESS_H |
3 | 31 | ||
4 | #include "odatebookaccessbackend.h" | 32 | #include "odatebookaccessbackend.h" |
5 | #include "opimaccesstemplate.h" | 33 | #include "opimaccesstemplate.h" |
6 | 34 | ||
7 | #include "oevent.h" | 35 | #include <opie2/oevent.h> |
8 | 36 | ||
37 | namespace Opie { | ||
9 | /** | 38 | /** |
10 | * This is the object orientated datebook database. It'll use OBackendFactory | 39 | * This is the object orientated datebook database. It'll use OBackendFactory |
11 | * to query for a backend. | 40 | * to query for a backend. |
12 | * All access to the datebook should be done via this class. | 41 | * All access to the datebook should be done via this class. |
13 | * Make sure to load and save the datebook this is not part of | 42 | * Make sure to load and save the datebook this is not part of |
14 | * destructing and creating the object | 43 | * destructing and creating the object |
15 | * | 44 | * |
16 | * @author Holger Freyther, Stefan Eilers | 45 | * @author Holger Freyther, Stefan Eilers |
17 | */ | 46 | */ |
18 | class ODateBookAccess : public OPimAccessTemplate<OEvent> { | 47 | class ODateBookAccess : public OPimAccessTemplate<OEvent> { |
19 | public: | 48 | public: |
20 | ODateBookAccess( ODateBookAccessBackend* = 0l, enum Access acc = Random ); | 49 | ODateBookAccess( ODateBookAccessBackend* = 0l, enum Access acc = Random ); |
21 | ~ODateBookAccess(); | 50 | ~ODateBookAccess(); |
22 | 51 | ||
23 | /* return all events */ | 52 | /* return all events */ |
24 | List rawEvents()const; | 53 | List rawEvents()const; |
25 | 54 | ||
26 | /* return repeating events */ | 55 | /* return repeating events */ |
27 | List rawRepeats()const; | 56 | List rawRepeats()const; |
28 | 57 | ||
29 | /* return non repeating events */ | 58 | /* return non repeating events */ |
30 | List nonRepeats()const; | 59 | List nonRepeats()const; |
31 | 60 | ||
32 | /* return non repeating events (from,to) */ | 61 | /* return non repeating events (from,to) */ |
33 | OEffectiveEvent::ValueList effectiveEvents( const QDate& from, const QDate& to ) const; | 62 | OEffectiveEvent::ValueList effectiveEvents( const QDate& from, const QDate& to ) const; |
34 | OEffectiveEvent::ValueList effectiveEvents( const QDateTime& start ) const; | 63 | OEffectiveEvent::ValueList effectiveEvents( const QDateTime& start ) const; |
35 | OEffectiveEvent::ValueList effectiveNonRepeatingEvents( const QDate& from, const QDate& to ) const; | 64 | OEffectiveEvent::ValueList effectiveNonRepeatingEvents( const QDate& from, const QDate& to ) const; |
36 | OEffectiveEvent::ValueList effectiveNonRepeatingEvents( const QDateTime& start ) const; | 65 | OEffectiveEvent::ValueList effectiveNonRepeatingEvents( const QDateTime& start ) const; |
37 | 66 | ||
38 | private: | 67 | private: |
39 | ODateBookAccessBackend* m_backEnd; | 68 | ODateBookAccessBackend* m_backEnd; |
40 | class Private; | 69 | class Private; |
41 | Private* d; | 70 | Private* d; |
42 | }; | 71 | }; |
43 | 72 | ||
73 | } | ||
74 | |||
44 | #endif | 75 | #endif |