31 #ifndef KCALCORE_ALARM_H
32 #define KCALCORE_ALARM_H
34 #include "kcalcore_export.h"
39 #include <KDE/KDateTime>
41 #include <QtCore/QString>
42 #include <QtCore/QStringList>
43 #include <QtCore/QVector>
76 typedef QSharedPointer<Alarm>
Ptr;
112 bool operator==(
const Alarm &a )
const;
119 bool operator!=(
const Alarm &a )
const;
141 QString parentUid()
const;
152 void setType(
Type type );
170 void setDisplayAlarm(
const QString &text = QString() );
180 void setText(
const QString &text );
188 QString text()
const;
199 void setAudioAlarm(
const QString &audioFile = QString() );
210 void setAudioFile(
const QString &audioFile );
218 QString audioFile()
const;
231 void setProcedureAlarm(
const QString &programFile,
232 const QString &arguments = QString() );
244 void setProgramFile(
const QString &programFile );
253 QString programFile()
const;
264 void setProgramArguments(
const QString &arguments );
273 QString programArguments()
const;
289 void setEmailAlarm(
const QString &subject,
const QString &text,
291 const QStringList &attachments = QStringList() );
303 void setMailAddress(
const Person::Ptr &mailAlarmAddress );
315 void setMailAddresses(
const Person::List &mailAlarmAddresses );
327 void addMailAddress(
const Person::Ptr &mailAlarmAddress );
347 void setMailSubject(
const QString &mailAlarmSubject );
355 QString mailSubject()
const;
367 void setMailAttachment(
const QString &mailAttachFile );
379 void setMailAttachments(
const QStringList &mailAttachFiles );
390 void addMailAttachment(
const QString &mailAttachFile );
398 QStringList mailAttachments()
const;
410 void setMailText(
const QString &text );
418 QString mailText()
const;
427 void setTime(
const KDateTime &alarmTime );
434 KDateTime time()
const;
444 KDateTime nextTime(
const KDateTime &preTime,
bool ignoreRepetitions =
false )
const;
452 KDateTime endTime()
const;
457 bool hasTime()
const;
467 void setStartOffset(
const Duration &offset );
484 bool hasStartOffset()
const;
494 void setEndOffset(
const Duration &offset );
511 bool hasEndOffset()
const;
527 void shiftTimes(
const KDateTime::Spec &oldSpec,
528 const KDateTime::Spec &newSpec );
537 void setSnoozeTime(
const Duration &alarmSnoozeTime );
555 void setRepeatCount(
int alarmRepeatCount );
562 int repeatCount()
const;
575 KDateTime nextRepetition(
const KDateTime &preTime )
const;
590 KDateTime previousRepetition(
const KDateTime &afterTime )
const;
612 void setEnabled(
bool enable );
619 bool enabled()
const;
627 void setHasLocationRadius(
bool hasLocationRadius );
634 bool hasLocationRadius()
const;
644 void setLocationRadius(
int locationRadius );
651 int locationRadius()
const;
658 virtual void customPropertyUpdated();
664 virtual void virtual_hook(
int id,
void *data );
This file is part of the API for handling calendar data and defines the CustomProperties class...
Represents a span of time measured in seconds or days.
QSharedPointer< Alarm > Ptr
A shared pointer to an Alarm object.
Represents an alarm notification.
Type
The different types of alarms.
QVector< Ptr > List
List of persons.
QVector< Ptr > List
List of alarms.
This file is part of the API for handling calendar data and defines the Person class.
This file is part of the API for handling calendar data and defines the Duration class.
QSharedPointer< Person > Ptr
A shared pointer to a Person object.
A class to manage custom calendar properties.
Provides the abstract base class common to non-FreeBusy (Events, To-dos, Journals) calendar component...