KCal Library
Go to the documentation of this file.
35 #ifndef KCAL_CALENDAR_H
36 #define KCAL_CALENDAR_H
38 #include <QtCore/QObject>
39 #include <QtCore/QString>
40 #include <QtCore/QList>
41 #include <QtCore/QMultiHash>
43 #include <kdatetime.h>
49 #include "kcalversion.h"
136 explicit Calendar(
const KDateTime::Spec &timeSpec );
151 explicit Calendar(
const QString &timeZoneId );
165 void setProductId(
const QString &
id );
172 QString productId()
const;
181 void setOwner(
const Person &owner );
200 void setTimeSpec(
const KDateTime::Spec &timeSpec );
208 KDateTime::Spec timeSpec()
const;
223 void setTimeZoneId(
const QString &timeZoneId );
232 QString timeZoneId()
const;
248 void setViewTimeSpec(
const KDateTime::Spec &timeSpec )
const;
268 void setViewTimeZoneId(
const QString &timeZoneId )
const;
276 KDateTime::Spec viewTimeSpec()
const;
284 QString viewTimeZoneId()
const;
302 void shiftTimes(
const KDateTime::Spec &oldSpec,
const KDateTime::Spec &newSpec );
329 void setModified(
bool modified );
338 bool isModified()
const;
365 virtual bool isSaving();
372 QStringList categories();
385 virtual bool addIncidence(
Incidence *incidence );
396 virtual bool deleteIncidence(
Incidence *incidence );
429 Incidence *incidence(
const QString &uid );
439 Incidence *incidenceFromSchedulingID(
const QString &sid );
467 virtual bool beginChange(
Incidence *incidence );
474 virtual bool endChange(
Incidence *incidence );
494 const KDateTime::Spec &spec,
495 bool single =
true );
555 const KDateTime::Spec &timeSpec,
593 Event::List events(
const QDate &start,
const QDate &end,
594 const KDateTime::Spec &timeSpec = KDateTime::Spec(),
595 bool inclusive =
false );
612 const KDateTime::Spec &timeSpec = KDateTime::Spec(),
653 const KDateTime::Spec &timeSpec = KDateTime::Spec(),
654 bool inclusive =
false ) = 0;
670 const QDate &date,
const KDateTime::Spec &timeSpec = KDateTime::Spec(),
746 virtual Todo::List todos(
const QDate &date );
885 void beginBatchAdding();
895 void endBatchAdding();
905 virtual void setupRelations(
Incidence *incidence );
913 virtual void removeRelations(
Incidence *incidence );
957 const KDateTime &to ) = 0;
981 virtual void calendarModified(
bool modified,
Calendar *calendar );
988 virtual void calendarIncidenceAdded(
Incidence *incidence );
995 virtual void calendarIncidenceChanged(
Incidence *incidence );
1002 virtual void calendarIncidenceDeleted(
Incidence *incidence );
1013 void registerObserver( CalendarObserver *observer );
1023 void unregisterObserver( CalendarObserver *observer );
1025 using QObject::event;
1069 virtual void doSetTimeSpec(
const KDateTime::Spec &timeSpec );
1076 void notifyIncidenceAdded(
Incidence *incidence );
1083 void notifyIncidenceChanged(
Incidence *incidence );
1090 void notifyIncidenceDeleted(
Incidence *incidence );
1096 virtual void customPropertyUpdated();
1104 void setObserversEnabled(
bool enabled );
1116 const KDateTime &from,
const KDateTime &to );
1128 const KDateTime &from,
const KDateTime &to );
@ EventSortSummary
Sort Events alphabetically, by summary.
JournalSortField
Calendar Journal sort keys.
A class to manage custom calendar properties.
virtual bool deleteEvent(Event *event)=0
Removes an Event from the calendar.
@ TodoSortDueDate
Sort Todos chronologically, by due date.
virtual ~CalendarObserver()
Destructor.
virtual Journal * journal(const QString &uid)=0
Returns the Journal associated with the given unique identifier.
virtual Todo * todo(const QString &uid)=0
Returns the Todo associated with the given unique identifier.
void calendarLoaded()
Signals that the calendar has been loaded into memory.
@ SortDirectionDescending
Sort in descending order (last to first)
virtual Todo::List rawTodosForDate(const QDate &date)=0
Returns an unfiltered list of all Todos which due on the specified date.
Represents a person, by name ane email address.
void setTimeZones(const ICalTimeZones &zones)
Set the time zone collection used by the calendar.
@ JournalSortUnsorted
Do not sort Journals.
virtual bool addTodo(Todo *todo)=0
Inserts a Todo into the calendar.
The CalendarObserver class.
@ TodoSortPriority
Sort Todos by priority.
Provides a filter for calendars.
This class provides an Event in the sense of RFC2445.
@ TodoSortUnsorted
Do not sort Todos.
@ SortDirectionAscending
Sort in ascending order (first to last)
virtual void deleteAllEvents()=0
Removes all Events from the calendar.
void calendarSaved()
Signals that the calendar has been saved.
Provides a To-do in the sense of RFC2445.
@ TodoSortStartDate
Sort Todos chronologically, by start date.
virtual Event::List rawEventsForDate(const KDateTime &dt)=0
Returns an unfiltered list of all Events which occur on the given timestamp.
virtual Event::List rawEventsForDate(const QDate &date, const KDateTime::Spec &timeSpec=KDateTime::Spec(), EventSortField sortField=EventSortUnsorted, SortDirection sortDirection=SortDirectionAscending)=0
Returns a sorted, unfiltered list of all Events which occur on the given date.
@ TodoSortPercentComplete
Sort Todos by percentage completed.
virtual bool reload()=0
Loads the calendar contents from storage.
The ICalTimeZones class represents a time zone database which consists of a collection of individual ...
TodoSortField
Calendar Todo sort keys.
void calendarChanged()
Signals that the calendar has been modified.
virtual Todo::List rawTodos(TodoSortField sortField=TodoSortUnsorted, SortDirection sortDirection=SortDirectionAscending)=0
Returns a sorted, unfiltered list of all Todos for this Calendar.
This file is part of the API for handling calendar data and defines the CustomProperties class.
virtual Journal::List rawJournalsForDate(const QDate &date)=0
Returns an unfiltered list of all Journals for on the specified date.
virtual bool deleteTodo(Todo *todo)=0
Removes a Todo from the calendar.
Represents the main calendar class.
@ JournalSortDate
Sort Journals chronologically by date.
EventSortField
Calendar Event sort keys.
This file is part of the API for handling calendar data and defines the Event class.
This class provides a template for lists of pointers.
virtual bool addJournal(Journal *journal)=0
Inserts a Journal into the calendar.
@ EventSortEndDate
Sort Events chronologically, by end date.
Provides the abstract base class common to non-FreeBusy (Events, To-dos, Journals) calendar component...
virtual Alarm::List alarms(const KDateTime &from, const KDateTime &to)=0
Returns a list of Alarms within a time range for this Calendar.
@ TodoSortSummary
Sort Todos alphabetically, by summary.
virtual bool deleteJournal(Journal *journal)=0
Removes a Journal from the calendar.
virtual bool save()=0
Syncs changes in memory to persistent storage.
virtual Event::List rawEvents(EventSortField sortField=EventSortUnsorted, SortDirection sortDirection=SortDirectionAscending)=0
Returns a sorted, unfiltered list of all Events for this Calendar.
@ EventSortStartDate
Sort Events chronologically, by start date.
SortDirection
Calendar Incidence sort directions.
This file is part of the API for handling calendar data and defines the Journal class.
virtual void deleteAllTodos()=0
Removes all To-dos from the calendar.
Provides a Journal in the sense of RFC2445.
virtual Journal::List rawJournals(JournalSortField sortField=JournalSortUnsorted, SortDirection sortDirection=SortDirectionAscending)=0
Returns a sorted, unfiltered list of all Journals for this Calendar.
This file is part of the API for handling calendar data and defines the Todo class.
The IncidenceObserver class.
@ JournalSortSummary
Sort Journals alphabetically, by summary.
virtual bool addEvent(Event *event)=0
Inserts an Event into the calendar.
@ EventSortUnsorted
Do not sort Events.
An abstract class that provides a common base for all calendar incidence classes.
virtual void deleteAllJournals()=0
Removes all Journals from the calendar.
virtual Event * event(const QString &uid)=0
Returns the Event associated with the given unique identifier.
virtual Event::List rawEvents(const QDate &start, const QDate &end, const KDateTime::Spec &timeSpec=KDateTime::Spec(), bool inclusive=false)=0
Returns an unfiltered list of all Events occurring within a date range.
virtual void close()=0
Clears out the current calendar, freeing all used memory etc.
This file is part of the KDE documentation.
Documentation copyright © 1996-2021 The KDE developers.
Generated on Tue Jul 27 2021 06:51:20 by
doxygen 1.8.20 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.