KCalendarCore
incidencebase.h
Go to the documentation of this file.
757 friend KCALENDARCORE_EXPORT QDataStream &operator<<(QDataStream &stream, const KCalendarCore::IncidenceBase::Ptr &);
759 friend KCALENDARCORE_EXPORT QDataStream &operator>>(QDataStream &stream, KCalendarCore::IncidenceBase::Ptr &);
779KCALENDARCORE_EXPORT QDataStream &operator<<(QDataStream &out, const KCalendarCore::IncidenceBase::Ptr &);
786KCALENDARCORE_EXPORT QDataStream &operator>>(QDataStream &in, KCalendarCore::IncidenceBase::Ptr &);
This file is part of the API for handling calendar data and defines the Attendee class.
Represents information related to an attendee of an Calendar Incidence, typically a meeting or task (...
Definition attendee.h:45
Represents a span of time measured in seconds or days.
Definition duration.h:44
Provides information about the free/busy time of a calendar.
Definition freebusy.h:43
The IncidenceObserver class.
Definition incidencebase.h:200
virtual void incidenceUpdate(const QString &uid, const QDateTime &recurrenceId)=0
The IncidenceObserver interface.
virtual void incidenceUpdated(const QString &uid, const QDateTime &recurrenceId)=0
The IncidenceObserver interface.
An abstract class that provides a common base for all calendar incidence classes.
Definition incidencebase.h:99
virtual void setDateTime(const QDateTime &dateTime, DateTimeRole role)=0
Sets the date/time corresponding to the specified DateTimeRole.
void addAttendee(const Attendee &attendee, bool doUpdate=true)
Add Attendee to this incidence.
Definition incidencebase.cpp:364
virtual bool accept(Visitor &v, const IncidenceBase::Ptr &incidence)
Accept IncidenceVisitor.
Definition incidencebase.cpp:163
void updated()
Call this to notify the observers after the IncidenceBase object has changed.
Definition incidencebase.cpp:518
virtual void setDtStart(const QDateTime &dtStart)
Sets the incidence's starting date/time with a QDateTime.
Definition incidencebase.cpp:246
QStringList comments() const
Returns all incidence comments as a list of strings.
Definition incidencebase.cpp:323
void addContact(const QString &contact)
Adds a contact to thieincidence.
Definition incidencebase.cpp:328
bool removeContact(const QString &contact)
Removes a contact from the incidence.
Definition incidencebase.cpp:338
virtual void shiftTimes(const QTimeZone &oldZone, const QTimeZone &newZone)
Shift the times of the incidence so that they appear at the same clock time as before but in a new ti...
Definition incidencebase.cpp:285
virtual void virtual_hook(VirtualHook id, void *data)=0
Standard trick to add virtuals later.
Duration duration() const
Returns the length of the incidence duration.
Definition incidencebase.cpp:467
void startUpdates()
Call this when a group of updates is going to be made.
Definition incidencebase.cpp:530
void addComment(const QString &comment)
Adds a comment to the incidence.
Definition incidencebase.cpp:294
Attendee attendeeByUid(const QString &uid) const
Returns the incidence attendee with the specified attendee UID.
Definition incidencebase.cpp:450
void setAttendees(const Attendee::List &attendees, bool doUpdate=true)
Set the attendees of this incidence.
Definition incidencebase.cpp:392
QSharedPointer< IncidenceBase > Ptr
A shared pointer to an IncidenceBase.
Definition incidencebase.h:113
void update()
Call this to notify the observers after the IncidenceBase object will be changed.
Definition incidencebase.cpp:507
QSet< IncidenceBase::Field > dirtyFields() const
Returns a QSet with all Fields that were changed since the incidence was created or resetDirtyFields(...
Definition incidencebase.cpp:566
IncidenceBase & operator=(const IncidenceBase &other)
Assignment operator.
Definition incidencebase.cpp:80
Attendee attendeeByMail(const QString &email) const
Returns the attendee with the specified email address.
Definition incidencebase.cpp:427
void customPropertyUpdate() override
Definition incidencebase.cpp:546
void setOrganizer(const Person &organizer)
Sets the organizer for the incidence.
Definition incidencebase.cpp:206
virtual void setDuration(const Duration &duration)
Sets the incidence duration.
Definition incidencebase.cpp:458
bool operator==(const IncidenceBase &ib) const
Compares this with IncidenceBase ib for equality.
Definition incidencebase.cpp:102
QUrl uri() const
Returns the uri for the incidence, of form urn:x-ical:<uid>
Definition incidencebase.cpp:576
virtual void setLastModified(const QDateTime &lm)
Sets the time the incidence was last modified to lm.
Definition incidencebase.cpp:185
@ FieldUnknown
Something changed. Always set when you use the assignment operator.
Definition incidencebase.h:190
@ FieldGeoLongitude
Field representing the longitude part of the GEO component.
Definition incidencebase.h:178
@ FieldRecurrence
Field representing the EXDATE, EXRULE, RDATE, and RRULE components.
Definition incidencebase.h:170
@ FieldPercentComplete
Field representing the PERCENT-COMPLETE component.
Definition incidencebase.h:166
@ FieldGeoLatitude
Field representing the latitude part of the GEO component.
Definition incidencebase.h:177
void setDirtyFields(const QSet< IncidenceBase::Field > &)
Sets which fields are dirty.
Definition incidencebase.cpp:581
virtual IncidenceBase & assign(const IncidenceBase &other)
Provides polymorfic assignment.
Definition incidencebase.cpp:92
Attendee attendeeByMails(const QStringList &emails, const QString &email=QString()) const
Returns the first incidence attendee with one of the specified email addresses.
Definition incidencebase.cpp:436
virtual QLatin1String mimeType() const =0
Returns the Akonadi specific sub MIME type of a KCalendarCore::IncidenceBase item,...
void setHasDuration(bool hasDuration)
Sets if the incidence has a duration.
Definition incidencebase.cpp:472
virtual void deserialize(QDataStream &in)
Sub-type specific deserialization.
Definition incidencebase.cpp:591
void endUpdates()
Call this when a group of updates is complete, to notify observers that the instance has changed.
Definition incidencebase.cpp:536
void unRegisterObserver(IncidenceObserver *observer)
Unregister observer.
Definition incidencebase.cpp:502
virtual QByteArray typeStr() const =0
Prints the type of incidence as a string.
void setFieldDirty(IncidenceBase::Field field)
Marks Field field as dirty.
Definition incidencebase.cpp:571
void customPropertyUpdated() override
Definition incidencebase.cpp:551
@ RoleAlarmStartOffset
Role for an incidence alarm's starting offset date/time.
Definition incidencebase.h:132
@ RoleDisplayEnd
Role used for display purposes, represents the end boundary if an incidence supports dtEnd.
Definition incidencebase.h:141
@ RoleAlarmEndOffset
Role for an incidence alarm's ending offset date/time.
Definition incidencebase.h:133
@ RoleStartTimeZone
Role for determining an incidence's starting timezone.
Definition incidencebase.h:136
@ RoleEnd
Role for determining an incidence's dtEnd, will return an invalid QDateTime if the incidence does not...
Definition incidencebase.h:139
@ RoleRecurrenceStart
Role for determining the start of the recurrence.
Definition incidencebase.h:145
@ RoleDisplayStart
Role for display purposes, represents the start boundary of an incidence.
Definition incidencebase.h:150
friend KCALENDARCORE_EXPORT QDataStream & operator>>(QDataStream &stream, KCalendarCore::IncidenceBase::Ptr &)
Incidence deserializer.
void setUid(const QString &uid)
Sets the unique id for the incidence to uid.
Definition incidencebase.cpp:170
virtual QDateTime recurrenceId() const
Returns the incidence recurrenceId.
Definition incidencebase.cpp:556
friend KCALENDARCORE_EXPORT QDataStream & operator<<(QDataStream &stream, const KCalendarCore::IncidenceBase::Ptr &)
Incidence serializer.
virtual void setAllDay(bool allDay)
Sets whether the incidence is all-day, i.e.
Definition incidencebase.cpp:272
bool isReadOnly() const
Returns true the object is read-only; false otherwise.
Definition incidencebase.cpp:241
bool operator!=(const IncidenceBase &ib) const
Compares this with IncidenceBase ib for inequality.
Definition incidencebase.cpp:112
QStringList contacts() const
Returns all incidence contacts as a list of strings.
Definition incidencebase.cpp:359
static quint32 magicSerializationIdentifier()
Constant that identifies KCalendarCore data in a binary stream.
Definition incidencebase.cpp:597
bool hasDuration() const
Returns true if the incidence has a duration; false otherwise.
Definition incidencebase.cpp:477
virtual QDateTime dateTime(DateTimeRole role) const =0
Returns a date/time corresponding to the specified DateTimeRole.
bool removeComment(const QString &comment)
Removes a comment from the incidence.
Definition incidencebase.cpp:302
void registerObserver(IncidenceObserver *observer)
Register observer.
Definition incidencebase.cpp:495
virtual bool equals(const IncidenceBase &incidenceBase) const
Provides polymorfic comparison for equality.
Definition incidencebase.cpp:117
virtual void serialize(QDataStream &out) const
Sub-type specific serialization.
Definition incidencebase.cpp:586
This class provides the interface for a visitor of calendar components.
Definition visitor.h:31
This file is part of the API for handling calendar data and defines the CustomProperties class.
This file is part of the API for handling calendar data and defines the Duration class.
KCALENDARCORE_EXPORT QDataStream & operator>>(QDataStream &in, const KCalendarCore::Alarm::Ptr &)
Alarm deserializer.
Definition alarm.cpp:833
KCALENDARCORE_EXPORT QDataStream & operator<<(QDataStream &out, const KCalendarCore::Alarm::Ptr &)
Alarm serializer.
Definition alarm.cpp:820
KCALENDARCORE_EXPORT bool identical(const QDateTime &dt1, const QDateTime &dt2)
Compare two QDateTimes for extended equality.
Definition incidencebase.cpp:608
This file is part of the API for handling calendar data and defines the Person class.
This file is part of the KDE documentation.
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 24 2025 11:53:53 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2025 The KDE developers.
Generated on Fri Jan 24 2025 11:53:53 by doxygen 1.13.2 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.