34 #include "kcal_export.h"
38 #include "recurrence.h"
40 #include <QtCore/QList>
41 #include <QtCore/QMetaType>
44 template <
typename T>
class shared_ptr;
81 AddVisitor( T *r ) : mResource( r ) {}
83 bool visit(
Event *e )
85 return mResource->addEvent( e );
89 return mResource->addTodo( t );
93 return mResource->addJournal( j );
115 DeleteVisitor( T *r ) : mResource( r ) {}
117 bool visit(
Event *e )
119 mResource->deleteEvent( e );
122 bool visit(
Todo *t )
124 mResource->deleteTodo( t );
129 mResource->deleteJournal( j );
165 SecrecyConfidential=2
176 typedef boost::shared_ptr<Incidence>
Ptr;
181 typedef boost::shared_ptr<const Incidence>
ConstPtr;
211 void setReadOnly(
bool readonly );
217 void setAllDay(
bool allDay );
232 void setCreated(
const KDateTime &dt );
238 KDateTime created()
const;
246 void setRevision(
int rev );
252 int revision()
const;
260 virtual void setDtStart(
const KDateTime &dt );
266 virtual KDateTime dtEnd()
const;
272 virtual void shiftTimes(
const KDateTime::Spec &oldSpec,
273 const KDateTime::Spec &newSpec );
282 void setDescription(
const QString &description,
bool isRich );
292 void setDescription(
const QString &description );
299 QString description()
const;
307 QString richDescription()
const;
313 bool descriptionIsRich()
const;
322 void setSummary(
const QString &summary,
bool isRich );
331 void setSummary(
const QString &summary );
338 QString summary()
const;
346 QString richSummary()
const;
352 bool summaryIsRich()
const;
361 void setLocation(
const QString &location,
bool isRich );
371 void setLocation(
const QString &location );
378 QString location()
const;
386 QString richLocation()
const;
392 bool locationIsRich()
const;
400 void setCategories(
const QStringList &categories );
409 void setCategories(
const QString &catStr );
415 QStringList categories()
const;
421 QString categoriesStr()
const;
430 void setRelatedToUid(
const QString &uid );
438 QString relatedToUid()
const;
447 void setRelatedTo(
Incidence *incidence );
469 void addRelation(
Incidence *incidence );
477 void removeRelation(
Incidence *incidence );
492 void clearRecurrence();
504 ushort recurrenceType()
const;
510 virtual bool recursOn(
const QDate &date,
const KDateTime::Spec &timeSpec )
const;
516 bool recursAt(
const KDateTime &dt )
const;
529 virtual QList<KDateTime> startDateTimesForDate(
531 const KDateTime::Spec &timeSpec = KDateTime::LocalZone )
const;
542 virtual QList<KDateTime> startDateTimesForDateTime(
543 const KDateTime &datetime )
const;
554 virtual KDateTime endDateForStart(
const KDateTime &startDt )
const;
575 void deleteAttachment(
Attachment *attachment );
584 void deleteAttachments(
const QString &mime );
604 void clearAttachments();
610 QString writeAttachmentToTempFile(
Attachment *attachment )
const;
612 void clearTempFiles();
624 void setSecrecy(
Secrecy secrecy );
636 QString secrecyStr()
const;
643 static QStringList secrecyList();
651 static QString secrecyName(
Secrecy secrecy );
660 void setStatus(
Status status );
669 void setCustomStatus(
const QString &status );
681 QString statusStr()
const;
688 static QString statusName(
Status status );
701 void setResources(
const QStringList &resources );
707 QStringList resources()
const;
717 void setPriority(
int priority );
723 int priority()
const;
738 void setHasGeo(
bool hasGeo );
746 void setGeoLatitude(
float geolatitude );
754 float &geoLatitude()
const;
762 void setGeoLongitude(
float geolongitude );
770 float &geoLongitude()
const;
792 void addAlarm(
Alarm *alarm );
800 void removeAlarm(
Alarm *alarm );
811 bool isAlarmEnabled()
const;
829 void setSchedulingID(
const QString &sid );
836 QString schedulingID()
const;
845 virtual void recurrenceUpdated(
Recurrence *recurrence );
871 bool operator==(
const Incidence &incidence )
const;
895 #define KCAL_INCIDENCE_METATYPE_DEFINED 1
virtual KDateTime endDateRecurrenceBase() const
Returns the end date/time of the base incidence (e.g.
boost::shared_ptr< Incidence > Ptr
A shared pointer to an Incidence.
Provides a To-do in the sense of RFC2445.
An abstract class that provides a common base for all calendar incidence classes. ...
This class provides an Event in the sense of RFC2445.
Status
Template for a class that implements a visitor for adding an Incidence to a resource supporting addEv...
This class provides the interface for a visitor of calendar components.
event or to-do canceled; journal removed
Provides the abstract base class common to non-FreeBusy (Events, To-dos, Journals) calendar component...
This class provides a template for lists of pointers.
Represents information related to an attachment for a Calendar Incidence.
Provides a Journal in the sense of RFC2445.
ListBase< Incidence > List
List of incidences.
Secrecy
The different types of incidence access classifications.
This file is part of the API for handling calendar data and defines the Attachment class...
This file is part of the API for handling calendar data and defines the Alarm class.
This file is part of the API for handling calendar data and defines the IncidenceBase class...
boost::shared_ptr< const Incidence > ConstPtr
A shared pointer to a non-mutable Incidence.
Provides information about the free/busy time of a calendar.
Represents an alarm notification.
This class represents a recurrence rule for a calendar incidence.