KCalendarCore

incidencebase.h
Go to the documentation of this file.
1 /*
2  This file is part of the kcalcore library.
3 
4  SPDX-FileCopyrightText: 2001-2003 Cornelius Schumacher <[email protected]>
5  SPDX-FileCopyrightText: 2003-2004 Reinhold Kainhofer <[email protected]>
6  SPDX-FileCopyrightText: 2005 Rafal Rzepecki <[email protected]>
7  SPDX-FileCopyrightText: 2009 Nokia Corporation and/or its subsidiary(-ies). All rights reserved.
8  SPDX-FileContributor: Alvaro Manera <[email protected]>
9 
10  SPDX-License-Identifier: LGPL-2.0-or-later
11 */
12 /**
13  @file
14  This file is part of the API for handling calendar data and
15  defines the IncidenceBase class.
16 
17  @author Cornelius Schumacher <[email protected]>
18  @author Reinhold Kainhofer <[email protected]>
19  @author Rafal Rzepecki <[email protected]>
20 
21  @glossary @anchor incidence @b incidence:
22  General term for a calendar component.
23  Examples are events, to-dos, and journals.
24 
25  @glossary @anchor event @b event:
26  An @ref incidence that has a start and end time, typically representing some
27  occurrence of social or personal importance. May be recurring.
28  Examples are appointments, meetings, or holidays.
29 
30  @glossary @anchor to-do @b to-do:
31  An @ref incidence that has an optional start time and an optional due time
32  typically representing some undertaking to be performed. May be recurring.
33  Examples are "fix the bug" or "pay the bills".
34 
35  @glossary @anchor todo @b todo:
36  See @ref to-do.
37 
38  @glossary @anchor journal @b journal:
39  An @ref incidence with a start date that represents a diary or daily record
40  of one's activities. May @b not be recurring.
41 */
42 
43 #ifndef KCALCORE_INCIDENCEBASE_H
44 #define KCALCORE_INCIDENCEBASE_H
45 
46 #include "attendee.h"
47 #include "customproperties.h"
48 #include "duration.h"
49 #include "person.h"
50 
51 #include <QDataStream>
52 #include <QDateTime>
53 #include <QSet>
54 #include <QSharedPointer>
55 #include <QUrl>
56 
57 class QUrl;
58 class QDate;
59 class QTimeZone;
60 
61 namespace KCalendarCore
62 {
63 /** List of dates */
65 
66 /** List of times */
68 
69 class Event;
70 class Todo;
71 class Journal;
72 class FreeBusy;
73 class Visitor;
74 
75 /**
76  @brief
77  An abstract class that provides a common base for all calendar incidence
78  classes.
79 
80  define: organizer (person)
81  define: uid (same as the attendee uid?)
82 
83  Several properties are not allowed for VFREEBUSY objects (see rfc:2445),
84  so they are not in IncidenceBase. The hierarchy is:
85 
86  IncidenceBase
87  + FreeBusy
88  + Incidence
89  + Event
90  + Todo
91  + Journal
92 
93  So IncidenceBase contains all properties that are common to all classes,
94  and Incidence contains all additional properties that are common to
95  Events, Todos and Journals, but are not allowed for FreeBusy entries.
96 */
97 class KCALENDARCORE_EXPORT IncidenceBase : public CustomProperties
98 {
99  Q_GADGET
100  Q_PROPERTY(QString uid READ uid WRITE setUid)
101  Q_PROPERTY(QDateTime lastModified READ lastModified WRITE setLastModified)
102  Q_PROPERTY(QDateTime dtStart READ dtStart WRITE setDtStart)
103  Q_PROPERTY(bool allDay READ allDay WRITE setAllDay)
104  Q_PROPERTY(KCalendarCore::Person organizer READ organizer WRITE setOrganizer)
105  Q_PROPERTY(QVariantList attendees READ attendeesVariant)
106 
107 public:
108  /**
109  A shared pointer to an IncidenceBase.
110  */
112 
113  /**
114  The different types of incidences, per RFC2445.
115  @see type(), typeStr()
116  */
118  TypeEvent = 0, /**< Type is an event */
119  TypeTodo, /**< Type is a to-do */
120  TypeJournal, /**< Type is a journal */
121  TypeFreeBusy, /**< Type is a free/busy */
122  TypeUnknown, /**< Type unknown */
123  };
124 
125  /**
126  The different types of incidence date/times roles.
127  @see dateTime()
128  */
130  RoleAlarmStartOffset = 0, /**< Role for an incidence alarm's starting offset date/time */
131  RoleAlarmEndOffset, /**< Role for an incidence alarm's ending offset date/time */
132  RoleSort, /**< Role for an incidence's date/time used when sorting */
133  RoleCalendarHashing, /**< Role for looking up an incidence in a Calendar */
134  RoleStartTimeZone, /**< Role for determining an incidence's starting timezone */
135  RoleEndTimeZone, /**< Role for determining an incidence's ending timezone */
136  RoleEndRecurrenceBase,
137  RoleEnd, /**< Role for determining an incidence's dtEnd, will return
138  an invalid QDateTime if the incidence does not support dtEnd */
139  RoleDisplayEnd, /**< Role used for display purposes, represents the end boundary
140  if an incidence supports dtEnd */
141  RoleAlarm, /**< Role for determining the date/time of the first alarm.
142  Returns invalid time if the incidence doesn't have any alarm */
143  RoleRecurrenceStart, /**< Role for determining the start of the recurrence.
144  Currently that's DTSTART for an event and DTDUE for a to-do.
145  (NOTE: If the incidence is a to-do, recurrence should be
146  calculated having DTSTART for a reference, not DT-DUE.
147  This is one place KCalendarCore isn't compliant with RFC2445) */
148  RoleDisplayStart, /**< Role for display purposes, represents the start boundary of an
149  incidence. To-dos return dtDue here, for historical reasons */
150  RoleDnD, /**< Role for determining new start and end dates after a DnD */
151  };
152 
153  /**
154  The different types of incidence fields.
155  */
156  enum Field {
157  FieldDtStart, ///< Field representing the DTSTART component.
158  FieldDtEnd, ///< Field representing the DTEND component.
159  FieldLastModified, ///< Field representing the LAST-MODIFIED component.
160  FieldDescription, ///< Field representing the DESCRIPTION component.
161  FieldSummary, ///< Field representing the SUMMARY component.
162  FieldLocation, ///< Field representing the LOCATION component.
163  FieldCompleted, ///< Field representing the COMPLETED component.
164  FieldPercentComplete, ///< Field representing the PERCENT-COMPLETE component.
165  FieldDtDue, ///< Field representing the DUE component.
166  FieldCategories, ///< Field representing the CATEGORIES component.
167  FieldRelatedTo, ///< Field representing the RELATED-TO component.
168  FieldRecurrence, ///< Field representing the EXDATE, EXRULE, RDATE, and RRULE components.
169  FieldAttachment, ///< Field representing the ATTACH component.
170  FieldSecrecy, ///< Field representing the CLASS component.
171  FieldStatus, ///< Field representing the STATUS component.
172  FieldTransparency, ///< Field representing the TRANSPARENCY component.
173  FieldResources, ///< Field representing the RESOURCES component.
174  FieldPriority, ///< Field representing the PRIORITY component.
175  FieldGeoLatitude, ///< Field representing the latitude part of the GEO component.
176  FieldGeoLongitude, ///< Field representing the longitude part of the GEO component.
177  FieldRecurrenceId, ///< Field representing the RECURRENCE-ID component.
178  FieldAlarms, ///< Field representing the VALARM component.
179  FieldSchedulingId, ///< Field representing the X-KDE-LIBKCAL-ID component.
180  FieldAttendees, ///< Field representing the ATTENDEE component.
181  FieldOrganizer, ///< Field representing the ORGANIZER component.
182  FieldCreated, ///< Field representing the CREATED component.
183  FieldRevision, ///< Field representing the SEQUENCE component.
184  FieldDuration, ///< Field representing the DURATION component.
185  FieldContact, ///< Field representing the CONTACT component.
186  FieldComment, ///< Field representing the COMMENT component.
187  FieldUid, ///< Field representing the UID component.
188  FieldUnknown, ///< Something changed. Always set when you use the assignment operator.
189  FieldUrl, ///< Field representing the URL component.
190  FieldConferences, ///< Field representing the CONFERENCE component.
191  FieldColor, ///< Field representing the COLOR component.
192  };
193 
194  /**
195  The IncidenceObserver class.
196  */
197  class KCALENDARCORE_EXPORT IncidenceObserver
198  {
199  public:
200  /**
201  Destroys the IncidenceObserver.
202  */
203  virtual ~IncidenceObserver();
204 
205  /**
206  The IncidenceObserver interface.
207  This function is called before any changes are made.
208  @param uid is the string containing the incidence @ref uid.
209  @param recurrenceId is possible recurrenceid of incidence.
210  */
211  virtual void incidenceUpdate(const QString &uid, const QDateTime &recurrenceId) = 0;
212 
213  /**
214  The IncidenceObserver interface.
215  This function is called after changes are completed.
216  @param uid is the string containing the incidence @ref uid.
217  @param recurrenceId is possible recurrenceid of incidence.
218  */
219  virtual void incidenceUpdated(const QString &uid, const QDateTime &recurrenceId) = 0;
220  };
221 
222  /**
223  Constructs an empty IncidenceBase.
224  */
225  IncidenceBase();
226 
227  /**
228  Destroys the IncidenceBase.
229  */
230  ~IncidenceBase() override;
231 
232  /**
233  Assignment operator.
234  All data belonging to derived classes are also copied. @see assign().
235  The caller guarantees that both types match.
236 
237  @code
238  if ( i1.type() == i2.type() ) {
239  i1 = i2;
240  } else {
241  qCDebug(KCALCORE_LOG) << "Invalid assignment!";
242  }
243  @endcode
244 
245  Dirty field FieldUnknown will be set.
246 
247  @param other is the IncidenceBase to assign.
248  */
249  IncidenceBase &operator=(const IncidenceBase &other);
250 
251  /**
252  Compares this with IncidenceBase @p ib for equality.
253  All data belonging to derived classes are also compared. @see equals().
254  @param ib is the IncidenceBase to compare against.
255  @return true if the incidences are equal; false otherwise.
256  */
257  bool operator==(const IncidenceBase &ib) const;
258 
259  /**
260  Compares this with IncidenceBase @p ib for inequality.
261  @param ib is the IncidenceBase to compare against.
262  @return true if the incidences are /not/ equal; false otherwise.
263  */
264  bool operator!=(const IncidenceBase &ib) const;
265 
266  /**
267  Accept IncidenceVisitor. A class taking part in the visitor mechanism
268  has to provide this implementation:
269  <pre>
270  bool accept(Visitor &v) { return v.visit(this); }
271  </pre>
272 
273  @param v is a reference to a Visitor object.
274  @param incidence is a valid IncidenceBase object for visiting.
275  */
276  virtual bool accept(Visitor &v, const IncidenceBase::Ptr &incidence);
277 
278  /**
279  Returns the incidence type.
280  */
281  virtual IncidenceType type() const = 0;
282 
283  /**
284  Prints the type of incidence as a string.
285  */
286  virtual QByteArray typeStr() const = 0;
287 
288  /**
289  Sets the unique id for the incidence to @p uid.
290  @param uid is the string containing the incidence @ref uid.
291  @see uid()
292  */
293  void setUid(const QString &uid);
294 
295  /**
296  Returns the unique id (@ref uid) for the incidence.
297  @see setUid()
298  */
299  Q_REQUIRED_RESULT QString uid() const;
300 
301  /**
302  Returns the uri for the incidence, of form urn:x-ical:<uid>
303  */
304  Q_REQUIRED_RESULT QUrl uri() const;
305 
306  /**
307  Sets the time the incidence was last modified to @p lm.
308  It is stored as a UTC date/time.
309 
310  @param lm is the QDateTime when the incidence was last modified.
311 
312  @see lastModified()
313  */
314  virtual void setLastModified(const QDateTime &lm);
315 
316  /**
317  Returns the time the incidence was last modified.
318  @see setLastModified()
319  */
320  Q_REQUIRED_RESULT QDateTime lastModified() const;
321 
322  /**
323  Sets the organizer for the incidence.
324 
325  @param organizer is a non-null Person to use as the incidence @ref organizer.
326  @see organizer(), setOrganizer(const QString &)
327  */
328  void setOrganizer(const Person &organizer);
329 
330  /**
331  Sets the incidence organizer to any string @p organizer.
332 
333  @param organizer is a string to use as the incidence @ref organizer.
334  @see organizer(), setOrganizer(const Person &)
335  */
336  void setOrganizer(const QString &organizer);
337 
338  /**
339  Returns the Person associated with this incidence.
340  If no Person was set through setOrganizer(), a default Person()
341  is returned.
342  @see setOrganizer(const QString &), setOrganizer(const Person &)
343  */
344  Person organizer() const;
345 
346  /**
347  Sets readonly status.
348 
349  @param readOnly if set, the incidence is read-only; else the incidence
350  can be modified.
351  @see isReadOnly().
352  */
353  virtual void setReadOnly(bool readOnly);
354 
355  /**
356  Returns true the object is read-only; false otherwise.
357  @see setReadOnly()
358  */
359  Q_REQUIRED_RESULT bool isReadOnly() const;
360 
361  /**
362  Sets the incidence's starting date/time with a QDateTime.
363 
364  @param dtStart is the incidence start date/time.
365  @see dtStart().
366  */
367  virtual void setDtStart(const QDateTime &dtStart);
368 
369  /**
370  Returns an incidence's starting date/time as a QDateTime.
371  @see setDtStart().
372  */
373  virtual QDateTime dtStart() const;
374 
375  /**
376  Sets the incidence duration.
377 
378  @param duration the incidence duration
379 
380  @see duration()
381  */
382  virtual void setDuration(const Duration &duration);
383 
384  /**
385  Returns the length of the incidence duration.
386  @see setDuration()
387  */
388  Q_REQUIRED_RESULT Duration duration() const;
389 
390  /**
391  Sets if the incidence has a duration.
392  @param hasDuration true if the incidence has a duration; false otherwise.
393  @see hasDuration()
394  */
395  void setHasDuration(bool hasDuration);
396 
397  /**
398  Returns true if the incidence has a duration; false otherwise.
399  @see setHasDuration()
400  */
401  Q_REQUIRED_RESULT bool hasDuration() const;
402 
403  /**
404  Returns true or false depending on whether the incidence is all-day.
405  i.e. has a date but no time attached to it.
406  @see setAllDay()
407  */
408  Q_REQUIRED_RESULT bool allDay() const;
409 
410  /**
411  Sets whether the incidence is all-day, i.e. has a date but no time
412  attached to it.
413 
414  @param allDay sets whether the incidence is all-day.
415 
416  @see allDay()
417  */
418  virtual void setAllDay(bool allDay);
419 
420  /**
421  Shift the times of the incidence so that they appear at the same clock
422  time as before but in a new time zone. The shift is done from a viewing
423  time zone rather than from the actual incidence time zone.
424 
425  For example, shifting an incidence whose start time is 09:00
426  America/New York, using an old viewing time zone (@p oldSpec)
427  of Europe/London, to a new time zone (@p newSpec) of Europe/Paris,
428  will result in the time being shifted from 14:00 (which is the London
429  time of the incidence start) to 14:00 Paris time.
430 
431  @param oldZone the time zone which provides the clock times
432  @param newZone the new time zone
433  */
434  virtual void shiftTimes(const QTimeZone &oldZone, const QTimeZone &newZone);
435 
436  /**
437  Adds a comment to the incidence. Does not add a linefeed character; simply
438  appends the text as specified.
439 
440  @param comment is the QString containing the comment to add.
441  @see removeComment().
442  */
443  void addComment(const QString &comment);
444 
445  /**
446  Removes a comment from the incidence. Removes the first comment whose
447  string is an exact match for the specified string in @p comment.
448 
449  @param comment is the QString containing the comment to remove.
450  @return true if match found, false otherwise.
451  @see addComment().
452  */
453  Q_REQUIRED_RESULT bool removeComment(const QString &comment);
454 
455  /**
456  Deletes all incidence comments.
457  */
458  void clearComments();
459 
460  /**
461  Returns all incidence comments as a list of strings.
462  */
463  Q_REQUIRED_RESULT QStringList comments() const;
464 
465  /**
466  Adds a contact to thieincidence. Does not add a linefeed character; simply
467  appends the text as specified.
468 
469  @param contact is the QString containing the contact to add.
470  @see removeContact().
471  */
472  void addContact(const QString &contact);
473 
474  /**
475  Removes a contact from the incidence. Removes the first contact whose
476  string is an exact match for the specified string in @p contact.
477 
478  @param contact is the QString containing the contact to remove.
479  @return true if match found, false otherwise.
480  @see addContact().
481  */
482  Q_REQUIRED_RESULT bool removeContact(const QString &contact);
483 
484  /**
485  Deletes all incidence contacts.
486  */
487  void clearContacts();
488 
489  /**
490  Returns all incidence contacts as a list of strings.
491  */
492  Q_REQUIRED_RESULT QStringList contacts() const;
493 
494  /**
495  Add Attendee to this incidence.
496 
497  @param attendee the attendee to add
498  @param doUpdate If true the Observers are notified, if false they are not.
499  */
500  void addAttendee(const Attendee &attendee, bool doUpdate = true);
501 
502  /**
503  Removes all attendees from the incidence.
504  */
505  void clearAttendees();
506 
507  /**
508  Set the attendees of this incidence.
509  This replaces all previously set attendees, unlike addAttendee.
510 
511  @param attendees A list of attendees.
512  @param doUpdate If true the Observers are notified, if false they are not.
513  */
514  void setAttendees(const Attendee::List &attendees, bool doUpdate = true);
515 
516  /**
517  Returns a list of incidence attendees.
518  All pointers in the list are valid.
519  */
520  Q_REQUIRED_RESULT Attendee::List attendees() const;
521 
522  /**
523  Returns the number of incidence attendees.
524  */
525  Q_REQUIRED_RESULT int attendeeCount() const;
526 
527  /**
528  Returns the attendee with the specified email address.
529 
530  @param email is a QString containing an email address of the
531  form "FirstName LastName <emailaddress>".
532  @see attendeeByMails(), attendeesByUid().
533  */
534  Attendee attendeeByMail(const QString &email) const;
535 
536  /**
537  Returns the first incidence attendee with one of the specified
538  email addresses.
539 
540  @param emails is a list of QStrings containing email addresses of the
541  form "FirstName LastName <emailaddress>".
542  @param email is a QString containing a single email address to search
543  in addition to the list specified in @p emails.
544  @see attendeeByMail(), attendeesByUid().
545  */
546  Attendee attendeeByMails(const QStringList &emails, const QString &email = QString()) const;
547 
548  /**
549  Returns the incidence attendee with the specified attendee @acronym UID.
550 
551  @param uid is a QString containing an attendee @acronym UID.
552  @see attendeeByMail(), attendeeByMails().
553  */
554  Attendee attendeeByUid(const QString &uid) const;
555 
556  /**
557  Sets the incidences url.
558 
559  This property can be used to point to a more dynamic rendition of the incidence.
560  I.e. a website related to the incidence.
561 
562  @param url of the incience.
563  @see url()
564  @since 4.12
565  */
566  void setUrl(const QUrl &url);
567 
568  /**
569  Returns the url.
570  @return incidences url value
571  @see setUrl()
572  @since 4.12
573  */
574  Q_REQUIRED_RESULT QUrl url() const;
575 
576  /**
577  Register observer. The observer is notified when the observed object
578  changes.
579 
580  @param observer is a pointer to an IncidenceObserver object that will be
581  watching this incidence.
582  @see unRegisterObserver()
583  */
584  void registerObserver(IncidenceObserver *observer);
585 
586  /**
587  Unregister observer. It isn't notified anymore about changes.
588 
589  @param observer is a pointer to an IncidenceObserver object that will be
590  watching this incidence.
591  @see registerObserver().
592  */
593  void unRegisterObserver(IncidenceObserver *observer);
594 
595  /**
596  Call this to notify the observers after the IncidenceBase object will be
597  changed.
598  */
599  void update();
600 
601  /**
602  Call this to notify the observers after the IncidenceBase object has
603  changed.
604  */
605  void updated();
606 
607  /**
608  Call this when a group of updates is going to be made. This suppresses
609  change notifications until endUpdates() is called, at which point
610  updated() will automatically be called.
611  */
612  void startUpdates();
613 
614  /**
615  Call this when a group of updates is complete, to notify observers that
616  the instance has changed. This should be called in conjunction with
617  startUpdates().
618  */
619  void endUpdates();
620 
621  /**
622  Returns a date/time corresponding to the specified DateTimeRole.
623  @param role is a DateTimeRole.
624  */
625  virtual QDateTime dateTime(DateTimeRole role) const = 0;
626 
627  /**
628  Sets the date/time corresponding to the specified DateTimeRole.
629  @param dateTime is QDateTime value to set.
630  @param role is a DateTimeRole.
631  */
632  virtual void setDateTime(const QDateTime &dateTime, DateTimeRole role) = 0;
633 
634  /**
635  Returns the Akonadi specific sub MIME type of a KCalendarCore::IncidenceBase item,
636  e.g. getting "application/x-vnd.akonadi.calendar.event" for a KCalendarCore::Event.
637  */
638  virtual QLatin1String mimeType() const = 0;
639 
640  /**
641  Returns the incidence recurrenceId.
642  @return incidences recurrenceId value
643  @see setRecurrenceId().
644  */
645  virtual QDateTime recurrenceId() const;
646 
647  /**
648  Returns a QSet with all Fields that were changed since the incidence was created
649  or resetDirtyFields() was called.
650 
651  @see resetDirtyFields()
652  */
653  QSet<IncidenceBase::Field> dirtyFields() const;
654 
655  /**
656  Sets which fields are dirty.
657  @see dirtyFields()
658  @since 4.8
659  */
660  void setDirtyFields(const QSet<IncidenceBase::Field> &);
661 
662  /**
663  Resets dirty fields.
664  @see dirtyFields()
665  */
666  void resetDirtyFields();
667 
668  /**
669  * Constant that identifies KCalendarCore data in a binary stream.
670  *
671  * @since 4.12
672  */
673  Q_REQUIRED_RESULT static quint32 magicSerializationIdentifier();
674 
675 protected:
676  /**
677  Marks Field @p field as dirty.
678  @param field is the Field type to mark as dirty.
679  @see dirtyFields()
680  */
681  void setFieldDirty(IncidenceBase::Field field);
682 
683  /**
684  @copydoc
685  CustomProperties::customPropertyUpdate()
686  */
687  void customPropertyUpdate() override;
688 
689  /**
690  @copydoc
691  CustomProperties::customPropertyUpdated()
692  */
693  void customPropertyUpdated() override;
694 
695  /**
696  Constructs an IncidenceBase as a copy of another IncidenceBase object.
697  @param ib is the IncidenceBase to copy.
698  */
699  IncidenceBase(const IncidenceBase &ib);
700 
701  /**
702  Provides polymorfic comparison for equality.
703  Only called by IncidenceBase::operator==() which guarantees that
704  @p incidenceBase is of the right type.
705  @param incidenceBase is the IncidenceBase to compare against.
706  @return true if the incidences are equal; false otherwise.
707  */
708  virtual bool equals(const IncidenceBase &incidenceBase) const;
709 
710  /**
711  Provides polymorfic assignment.
712  @param other is the IncidenceBase to assign.
713  */
714  virtual IncidenceBase &assign(const IncidenceBase &other);
715 
716  /**
717  * Sub-type specific serialization.
718  */
719  virtual void serialize(QDataStream &out) const;
720  /**
721  * Sub-type specific deserialization.
722  */
723  virtual void deserialize(QDataStream &in);
724 
725  enum VirtualHook {};
726 
727  /**
728  Standard trick to add virtuals later.
729 
730  @param id is any integer unique to this class which we will use to identify the method
731  to be called.
732  @param data is a pointer to some glob of data, typically a struct.
733  */
734  virtual void virtual_hook(VirtualHook id, void *data) = 0;
735 
736  /**
737  Identifies a read-only incidence.
738  */
739  bool mReadOnly;
740 
741 private:
742  //@cond PRIVATE
743  class Private;
744  Private *const d;
745 
746  Q_DECL_HIDDEN QVariantList attendeesVariant() const;
747  //@endcond
748 
749  friend KCALENDARCORE_EXPORT QDataStream &operator<<(QDataStream &stream, const KCalendarCore::IncidenceBase::Ptr &);
750 
751  friend KCALENDARCORE_EXPORT QDataStream &operator>>(QDataStream &stream, KCalendarCore::IncidenceBase::Ptr &);
752 };
753 
754 /**
755  * Incidence serializer.
756  *
757  * @since 4.12
758  */
759 KCALENDARCORE_EXPORT QDataStream &operator<<(QDataStream &out, const KCalendarCore::IncidenceBase::Ptr &);
760 
761 /**
762  * Incidence deserializer.
763  *
764  * @since 4.12
765  */
767 }
768 
769 Q_DECLARE_METATYPE(KCalendarCore::IncidenceBase *)
770 Q_DECLARE_METATYPE(KCalendarCore::IncidenceBase::Ptr)
771 
772 #endif
KCALENDARCORE_EXPORT QDataStream & operator<<(QDataStream &out, const KCalendarCore::Alarm::Ptr &)
Alarm serializer.
Definition: alarm.cpp:820
This file is part of the API for handling calendar data and defines the Attendee class.
Field representing the CREATED component.
Role for determining new start and end dates after a DnD.
A class to manage custom calendar properties.
This class provides the interface for a visitor of calendar components.
Definition: visitor.h:30
This file is part of the API for handling calendar data and defines the CustomProperties class...
Represents a person, by name and email address.
Definition: person.h:37
Field representing the COMPLETED component.
Represents information related to an attendee of an Calendar Incidence, typically a meeting or task (...
Definition: attendee.h:44
Provides a Journal in the sense of RFC2445.
Definition: journal.h:29
Field representing the URL component.
KCALENDARCORE_EXPORT QDataStream & operator>>(QDataStream &in, const KCalendarCore::Alarm::Ptr &)
Alarm deserializer.
Definition: alarm.cpp:833
Provides information about the free/busy time of a calendar.
Definition: freebusy.h:41
Field representing the EXDATE, EXRULE, RDATE, and RRULE components.
Field
The different types of incidence fields.
Field representing the PRIORITY component.
Field representing the STATUS component.
Field representing the RECURRENCE-ID component.
DateTimeRole
The different types of incidence date/times roles.
Field representing the TRANSPARENCY component.
An abstract class that provides a common base for all calendar incidence classes. ...
Definition: incidencebase.h:97
Role for an incidence&#39;s date/time used when sorting.
This file is part of the API for handling calendar data and defines the Person class.
Field representing the X-KDE-LIBKCAL-ID component.
Represents a span of time measured in seconds or days.
Definition: duration.h:43
Role for determining an incidence&#39;s starting timezone.
Field representing the CATEGORIES component.
Role for determining an incidence&#39;s ending timezone.
This class provides an Event in the sense of RFC2445.
Definition: event.h:29
Field representing the PERCENT-COMPLETE component.
Role for looking up an incidence in a Calendar.
Something changed. Always set when you use the assignment operator.
Provides a To-do in the sense of RFC2445.
Definition: todo.h:30
IncidenceType
The different types of incidences, per RFC2445.
Field representing the DUE component.
Field representing the RESOURCES component.
Field representing the CONTACT component.
Field representing the longitude part of the GEO component.
Field representing the ORGANIZER component.
Field representing the DTEND component.
Field representing the ATTENDEE component.
Field representing the COMMENT component.
QSharedPointer< IncidenceBase > Ptr
A shared pointer to an IncidenceBase.
Field representing the DTSTART component.
Field representing the UID component.
This file is part of the API for handling calendar data and defines the Duration class.
Field representing the LOCATION component.
Field representing the COLOR component.
Field representing the ATTACH component.
Field representing the RELATED-TO component.
Field representing the DESCRIPTION component.
Field representing the latitude part of the GEO component.
Field representing the VALARM component.
Field representing the CLASS component.
QList< QDate > DateList
List of dates.
Definition: incidencebase.h:64
Field representing the SEQUENCE component.
Field representing the DURATION component.
Field representing the CONFERENCE component.
Field representing the LAST-MODIFIED component.
Field representing the SUMMARY component.
Namespace for all KCalendarCore types.
Definition: alarm.h:36
Role for an incidence alarm&#39;s ending offset date/time.
QList< QDateTime > DateTimeList
List of times.
Definition: incidencebase.h:67
bool mReadOnly
Identifies a read-only incidence.
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Mon Jul 26 2021 22:51:12 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.