• Skip to content
  • Skip to link menu
  • KDE API Reference
  • kdepimlibs-4.14.10 API Reference
  • KDE Home
  • Contact Us
 

KCal Library

  • kcal
calendarlocal.h
Go to the documentation of this file.
1/*
2 This file is part of the kcal library.
3
4 Copyright (c) 1998 Preston Brown <pbrown@kde.org>
5 Copyright (c) 2001,2003 Cornelius Schumacher <schumacher@kde.org>
6
7 This library is free software; you can redistribute it and/or
8 modify it under the terms of the GNU Library General Public
9 License as published by the Free Software Foundation; either
10 version 2 of the License, or (at your option) any later version.
11
12 This library is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 Library General Public License for more details.
16
17 You should have received a copy of the GNU Library General Public License
18 along with this library; see the file COPYING.LIB. If not, write to
19 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20 Boston, MA 02110-1301, USA.
21*/
30#ifndef KCAL_CALENDARLOCAL_H
31#define KCAL_CALENDARLOCAL_H
32
33#include "calendar.h"
34
35namespace KCal {
36
37class CalFormat;
38
43class KCAL_DEPRECATED_EXPORT CalendarLocal : public Calendar
44{
45 public:
50 explicit CalendarLocal( const KDateTime::Spec &timeSpec );
51
56 explicit CalendarLocal( const QString &timeZoneId );
57
62 ~CalendarLocal();
63
80 bool load( const QString &fileName, CalFormat *format = 0 );
81
87 bool reload();
88
96 bool save();
97
108 bool save( const QString &fileName, CalFormat *format = 0 );
109
113 void close();
114
115 // Event Specific Methods //
116
121 bool addEvent( Event *event );
122
127 bool deleteEvent( Event *event );
128
133 void deleteAllEvents();
134
139 Event::List rawEvents(
140 EventSortField sortField = EventSortUnsorted,
141 SortDirection sortDirection = SortDirectionAscending );
142
147 Event::List rawEvents( const QDate &start, const QDate &end,
148 const KDateTime::Spec &timeSpec = KDateTime::Spec(),
149 bool inclusive = false );
150
162 Event::List rawEventsForDate(
163 const QDate &date, const KDateTime::Spec &timeSpec = KDateTime::Spec(),
164 EventSortField sortField = EventSortUnsorted,
165 SortDirection sortDirection = SortDirectionAscending );
166
171 Event::List rawEventsForDate( const KDateTime &dt );
172
177 Event *event( const QString &uid );
178
179 // To-do Specific Methods //
180
185 bool addTodo( Todo *todo );
186
191 bool deleteTodo( Todo *todo );
192
197 void deleteAllTodos();
198
203 Todo::List rawTodos(
204 TodoSortField sortField = TodoSortUnsorted,
205 SortDirection sortDirection = SortDirectionAscending );
206
211 Todo::List rawTodosForDate( const QDate &date );
212
217 Todo *todo( const QString &uid );
218
219 // Journal Specific Methods //
220
225 bool addJournal( Journal *journal );
226
231 bool deleteJournal( Journal *journal );
232
237 void deleteAllJournals();
238
243 Journal::List rawJournals(
244 JournalSortField sortField = JournalSortUnsorted,
245 SortDirection sortDirection = SortDirectionAscending );
246
251 Journal::List rawJournalsForDate( const QDate &date );
252
257 Journal *journal( const QString &uid );
258
259 // Alarm Specific Methods //
260
265 Alarm::List alarms( const KDateTime &from, const KDateTime &to );
266
273 Alarm::List alarmsTo( const KDateTime &to );
274
280 void incidenceUpdated( IncidenceBase *incidenceBase );
281
282 using QObject::event; // prevent warning about hidden virtual method
283
284 private:
285 //@cond PRIVATE
286 Q_DISABLE_COPY( CalendarLocal )
287 class Private;
288 Private *const d;
289 //@endcond
290};
291
292}
293
294#endif
calendar.h
This file is part of the API for handling calendar data and defines the Calendar class.
KCal::TodoSortField
TodoSortField
Calendar Todo sort keys.
Definition calendar.h:79
KCal::TodoSortUnsorted
@ TodoSortUnsorted
Do not sort Todos.
Definition calendar.h:80
KCal::JournalSortField
JournalSortField
Calendar Journal sort keys.
Definition calendar.h:91
KCal::JournalSortUnsorted
@ JournalSortUnsorted
Do not sort Journals.
Definition calendar.h:92
KCal::EventSortField
EventSortField
Calendar Event sort keys.
Definition calendar.h:69
KCal::EventSortUnsorted
@ EventSortUnsorted
Do not sort Events.
Definition calendar.h:70
KCal::SortDirection
SortDirection
Calendar Incidence sort directions.
Definition calendar.h:61
KCal::SortDirectionAscending
@ SortDirectionAscending
Sort in ascending order (first to last)
Definition calendar.h:62
KCal::CalFormat
An abstract base class that provides an interface to various calendar formats.
Definition calformat.h:52
KCal::CalendarLocal
This class provides a calendar stored as a local file.
Definition calendarlocal.h:44
KCal::Calendar
Represents the main calendar class.
Definition calendar.h:121
KCal::Event
This class provides an Event in the sense of RFC2445.
Definition event.h:42
KCal::IncidenceBase
An abstract class that provides a common base for all calendar incidence classes.
Definition incidencebase.h:103
KCal::Journal
Provides a Journal in the sense of RFC2445.
Definition journal.h:44
KCal::ListBase
This class provides a template for lists of pointers.
Definition listbase.h:45
KCal::Todo
Provides a To-do in the sense of RFC2445.
Definition todo.h:45
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Wed Jan 24 2024 00:00:00 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

KCal Library

Skip menu "KCal Library"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members
  • Related Pages

kdepimlibs-4.14.10 API Reference

Skip menu "kdepimlibs-4.14.10 API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kioslave
  •   imap4
  •   mbox
  •   nntp
  • kldap
  • kmbox
  • kmime
  • kontactinterface
  • kpimidentities
  • kpimtextedit
  • kpimutils
  • kresources
  • ktnef
  • kxmlrpcclient
  • mailtransport
  • microblog
  • qgpgme
  • syndication
  •   atom
  •   rdf
  •   rss2
Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal