kalarm

kalarmiface.h

Go to the documentation of this file.
00001 /*
00002  *  kalarmiface.h  -  DCOP interface to KAlarm
00003  *  Program:  kalarm
00004  *  Copyright © 2004-2006 by David Jarvie <software@astrojar.org.uk>
00005  *
00006  *  This program is free software; you can redistribute it and/or modify
00007  *  it under the terms of the GNU General Public License as published by
00008  *  the Free Software Foundation; either version 2 of the License, or
00009  *  (at your option) any later version.
00010  *
00011  *  This program is distributed in the hope that it will be useful,
00012  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00014  *  GNU General Public License for more details.
00015  *
00016  *  You should have received a copy of the GNU General Public License along
00017  *  with this program; if not, write to the Free Software Foundation, Inc.,
00018  *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00019  */
00020 
00021 #ifndef KALARMIFACE_H
00022 #define KALARMIFACE_H
00023 
00026 // No forward declarations - dcopidl2cpp won't work
00027 #include <dcopobject.h>
00028 #include <kurl.h>
00029 #include <qstringlist.h>
00030 class QString;
00031 
00036 class KAlarmIface : virtual public DCOPObject
00037 {
00038     K_DCOP
00039     public:
00054     enum Flags
00055     {
00056         REPEAT_AT_LOGIN = 0x01,    // repeat alarm at every login
00057         BEEP            = 0x02,    // sound audible beep when alarm is displayed
00058         REPEAT_SOUND    = 0x08,    // repeat sound file while alarm is displayed
00059         CONFIRM_ACK     = 0x04,    // closing the alarm message window requires confirmation prompt
00060         AUTO_CLOSE      = 0x10,    // auto-close alarm window after late-cancel period
00061         EMAIL_BCC       = 0x20,    // blind copy the email to the user
00062         DISABLED        = 0x40,    // alarm is currently disabled
00063         SCRIPT          = 0x80,    // command is a script, not a shell command line
00064         EXEC_IN_XTERM   = 0x100,   // execute command alarm in terminal window
00065         SPEAK           = 0x200,   // speak the alarm message when it is displayed
00066         SHOW_IN_KORG    = 0x400    // show the alarm as an event in KOrganizer
00067     };
00075     enum RecurType
00076     {
00077         MINUTELY = 1,    // the repeat interval is measured in minutes
00078         DAILY    = 2,    // the repeat interval is measured in days
00079         WEEKLY   = 3,    // the repeat interval is measured in weeks
00080         MONTHLY  = 4,    // the repeat interval is measured in months
00081         YEARLY   = 5     // the repeat interval is measured in years
00082     };
00083 
00084     k_dcop:
00091     virtual bool cancelEvent(const QString& url, const QString& eventId) = 0;
00092 
00099     virtual bool triggerEvent(const QString& url, const QString& eventId) = 0;
00100 
00122     virtual bool scheduleMessage(const QString& message, const QString& startDateTime, int lateCancel, unsigned flags,
00123                                  const QString& bgColor, const QString& fgColor, const QString& font,
00124                                  const KURL& audioFile, int reminderMins, const QString& recurrence,
00125                                  int repeatInterval, int repeatCount) = 0;
00149     virtual bool scheduleMessage(const QString& message, const QString& startDateTime, int lateCancel, unsigned flags,
00150                                  const QString& bgColor, const QString& fgColor, const QString& font,
00151                                  const KURL& audioFile, int reminderMins,
00152                                  int repeatType, int repeatInterval, int repeatCount) = 0;
00176     virtual bool scheduleMessage(const QString& message, const QString& startDateTime, int lateCancel, unsigned flags,
00177                                  const QString& bgColor, const QString& fgColor, const QString& font,
00178                                  const KURL& audioFile, int reminderMins,
00179                                  int repeatType, int repeatInterval, const QString& endDateTime) = 0;
00180     
00197     virtual bool scheduleFile(const KURL& file, const QString& startDateTime, int lateCancel, unsigned flags, const QString& bgColor,
00198                               const KURL& audioFile, int reminderMins, const QString& recurrence,
00199                               int repeatInterval, int repeatCount) = 0;
00218     virtual bool scheduleFile(const KURL& file, const QString& startDateTime, int lateCancel, unsigned flags, const QString& bgColor,
00219                               const KURL& audioFile, int reminderMins, int repeatType, int repeatInterval, int repeatCount) = 0;
00238     virtual bool scheduleFile(const KURL& file, const QString& startDateTime, int lateCancel, unsigned flags, const QString& bgColor,
00239                               const KURL& audioFile, int reminderMins,
00240                               int repeatType, int repeatInterval, const QString& endDateTime) = 0;
00241     
00252     virtual bool scheduleCommand(const QString& commandLine, const QString& startDateTime, int lateCancel, unsigned flags,
00253                                  const QString& recurrence, int repeatInterval, int repeatCount) = 0;
00266     virtual bool scheduleCommand(const QString& commandLine, const QString& startDateTime, int lateCancel, unsigned flags,
00267                                  int repeatType, int repeatInterval, int repeatCount) = 0;
00280     virtual bool scheduleCommand(const QString& commandLine, const QString& startDateTime, int lateCancel, unsigned flags,
00281                                  int repeatType, int repeatInterval, const QString& endDateTime) = 0;
00282 
00298     virtual bool scheduleEmail(const QString& fromID, const QString& addresses, const QString& subject, const QString& message,
00299                                const QString& attachments, const QString& startDateTime, int lateCancel, unsigned flags,
00300                                const QString& recurrence, int repeatInterval, int repeatCount) = 0;
00318     virtual bool scheduleEmail(const QString& fromID, const QString& addresses, const QString& subject, const QString& message,
00319                                const QString& attachments, const QString& startDateTime, int lateCancel, unsigned flags,
00320                                int repeatType, int repeatInterval, int repeatCount) = 0;
00338     virtual bool scheduleEmail(const QString& fromID, const QString& addresses, const QString& subject, const QString& message,
00339                                const QString& attachments, const QString& startDateTime, int lateCancel, unsigned flags,
00340                                int repeatType, int repeatInterval, const QString& endDateTime) = 0;
00345     virtual bool edit(const QString& eventID) = 0;
00352     virtual bool editNew(const QString& templateName) = 0;
00353 };
00354 
00355 #endif // KALARMIFACE_H
KDE Home | KDE Accessibility Home | Description of Access Keys