summaryrefslogtreecommitdiff
path: root/libopie2/opiepim/core/opimnotifymanager.h
Unidiff
Diffstat (limited to 'libopie2/opiepim/core/opimnotifymanager.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiepim/core/opimnotifymanager.h40
1 files changed, 21 insertions, 19 deletions
diff --git a/libopie2/opiepim/core/opimnotifymanager.h b/libopie2/opiepim/core/opimnotifymanager.h
index 0272e5d..9241ea2 100644
--- a/libopie2/opiepim/core/opimnotifymanager.h
+++ b/libopie2/opiepim/core/opimnotifymanager.h
@@ -25,23 +25,27 @@
25 If not, write to the Free Software Foundation, 25 If not, write to the Free Software Foundation,
26 Inc., 59 Temple Place - Suite 330, 26 Inc., 59 Temple Place - Suite 330,
27 Boston, MA 02111-1307, USA. 27 Boston, MA 02111-1307, USA.
28*/ 28*/
29#ifndef OPIE_PIM_NOTIFY_MANAGER_H 29#ifndef OPIMNOTIFYMANAGER_H
30#define OPIE_PIM_NOTIFY_MANAGER_H 30#define OPIMNOTIFYMANAGER_H
31
32#include <qvaluelist.h>
33 31
32/* OPIE */
34#include <opie2/opimnotify.h> 33#include <opie2/opimnotify.h>
35 34
36namespace Opie { 35/* QT */
36#include <qvaluelist.h>
37
38namespace Opie
39{
37/** 40/**
38 * The notify manager keeps track of the Notifiers.... 41 * The notify manager keeps track of the Notifiers....
39 */ 42 */
40class OPimNotifyManager { 43class OPimNotifyManager
41public: 44{
45 public:
42 typedef QValueList<OPimReminder> Reminders; 46 typedef QValueList<OPimReminder> Reminders;
43 typedef QValueList<OPimAlarm> Alarms; 47 typedef QValueList<OPimAlarm> Alarms;
44 OPimNotifyManager( const Reminders& rems = Reminders(), const Alarms& alarms = Alarms() ); 48 OPimNotifyManager( const Reminders& rems = Reminders(), const Alarms& alarms = Alarms() );
45 ~OPimNotifyManager(); 49 ~OPimNotifyManager();
46 50
47 /* we will cast it for you ;) */ 51 /* we will cast it for you ;) */
@@ -49,22 +53,22 @@ public:
49 void remove( const OPimNotify& ); 53 void remove( const OPimNotify& );
50 /* replaces all with this one! */ 54 /* replaces all with this one! */
51 void replace( const OPimNotify& ); 55 void replace( const OPimNotify& );
52 56
53 Reminders reminders()const; 57 Reminders reminders() const;
54 58
55 /** 59 /**
56 * Return 60 * Return
57 */ 61 */
58 Alarms alarms()const; 62 Alarms alarms() const;
59 63
60 /** 64 /**
61 * Return alarm at DateTime "when". If more than one is registered at this 65 * Return alarm at DateTime "when". If more than one is registered at this
62 * DateTime, the first one is returned. 66 * DateTime, the first one is returned.
63 * If none was found, an empty Alarm is returned. 67 * If none was found, an empty Alarm is returned.
64 * @param when The date and time of the returned alarm 68 * @param when The date and time of the returned alarm
65 * @param found Returns true if anything was found. 69 * @param found Returns true if anything was found.
66 * @return Returns the found alarm at given DateTime. It is empty if found is false 70 * @return Returns the found alarm at given DateTime. It is empty if found is false
67 * (nothing could be found at given date and time) 71 * (nothing could be found at given date and time)
68 */ 72 */
69 OPimAlarm alarmAtDateTime( const QDateTime& when, bool& found ) const; 73 OPimAlarm alarmAtDateTime( const QDateTime& when, bool& found ) const;
70 74
@@ -82,21 +86,21 @@ public:
82 * this will do the opposite.. 86 * this will do the opposite..
83 */ 87 */
84 void deregister( const OPimNotify& ); 88 void deregister( const OPimNotify& );
85 89
86 bool isEmpty()const; 90 bool isEmpty() const;
87 91
88 /** 92 /**
89 * Return all alarms as string 93 * Return all alarms as string
90 */ 94 */
91 QString alarmsToString() const; 95 QString alarmsToString() const;
92 /** 96 /**
93 * Return all notifiers as string 97 * Return all notifiers as string
94 */ 98 */
95 QString remindersToString() const; 99 QString remindersToString() const;
96 100
97 /** 101 /**
98 * Convert string to alarms 102 * Convert string to alarms
99 * @param str String created by alarmsToString() 103 * @param str String created by alarmsToString()
100 */ 104 */
101 void alarmsFromString( const QString& str ); 105 void alarmsFromString( const QString& str );
102 106
@@ -105,11 +109,9 @@ public:
105 * @param str String created by remindersToString() 109 * @param str String created by remindersToString()
106 */ 110 */
107 void remindersFromString( const QString& str ); 111 void remindersFromString( const QString& str );
108 112
109 113 private:
110
111private:
112 Reminders m_rem; 114 Reminders m_rem;
113 Alarms m_al; 115 Alarms m_al;
114 116
115 class Private; 117 class Private;