KCalCore Library
#include <vcalformat.h>
Public Member Functions | |
VCalFormat () | |
virtual | ~VCalFormat () |
bool | fromRawString (const Calendar::Ptr &calendar, const QByteArray &string, bool deleted=false, const QString ¬ebook=QString()) |
bool | fromString (const Calendar::Ptr &calendar, const QString &string, bool deleted=false, const QString ¬ebook=QString()) |
bool | load (const Calendar::Ptr &calendar, const QString &fileName) |
bool | save (const Calendar::Ptr &calendar, const QString &fileName) |
QString | toString (const Calendar::Ptr &calendar, const QString ¬ebook=QString(), bool deleted=false) |
Public Member Functions inherited from KCalCore::CalFormat | |
CalFormat () | |
virtual | ~CalFormat () |
void | clearException () |
Exception * | exception () const |
QString | loadedProductId () |
void | setException (Exception *error) |
Protected Member Functions | |
const char * | dayFromNum (int day) |
VObject * | eventToVEvent (const Event::Ptr &event) |
VObject * | eventToVTodo (const Todo::Ptr &todo) |
KDateTime | ISOToKDateTime (const QString &dtStr) |
QDate | ISOToQDate (const QString &dtStr) |
QString | kDateTimeToISO (const KDateTime &date, bool zulu=true) |
int | numFromDay (const QString &day) |
QString | parseDst (QByteArray &timezone) const |
QString | parseTZ (const QByteArray &timezone) const |
bool | parseTZOffsetISO8601 (const QString &s, int &result) |
void | populate (VObject *vcal, bool deleted=false, const QString ¬ebook=QString()) |
QString | qDateToISO (const QDate &date) |
void | readCustomProperties (VObject *o, const Incidence::Ptr &i) |
Attendee::PartStat | readStatus (const char *s) const |
Event::Ptr | VEventToEvent (VObject *vevent) |
virtual void | virtual_hook (int id, void *data) |
Todo::Ptr | VTodoToEvent (VObject *vtodo) |
void | writeCustomProperties (VObject *o, const Incidence::Ptr &i) |
QByteArray | writeStatus (Attendee::PartStat status) const |
Protected Member Functions inherited from KCalCore::CalFormat | |
void | setLoadedProductId (const QString &id) |
Additional Inherited Members | |
Static Public Member Functions inherited from KCalCore::CalFormat | |
static const QString & | application () |
static QString | createUniqueId () |
static const QString & | productId () |
static void | setApplication (const QString &application, const QString &productID) |
Detailed Description
vCalendar format implementation.
This class implements the vCalendar format. It provides methods for loading/saving/converting vCalendar format data into the internal representation as Calendar and Incidences.
Definition at line 69 of file vcalformat.h.
Constructor & Destructor Documentation
VCalFormat::VCalFormat | ( | ) |
Constructor a new vCalendar Format object.
Private class that helps to provide binary compatibility between releases.
Definition at line 88 of file vcalformat.cpp.
|
virtual |
Destructor.
Definition at line 98 of file vcalformat.cpp.
Member Function Documentation
|
protected |
Takes a number 0 - 6 and returns the two letter string of that day, i.e.
MO, TU, WE, etc.
- Parameters
-
day number of the day to get a two letter name for. Range 0
-6
- See also
- numFromDay().
Definition at line 2549 of file vcalformat.cpp.
|
protected |
Translates an Event into a VEvent-type VObject and returns a pointer to it.
- Parameters
-
event is a pointer to a valid Event object.
Definition at line 656 of file vcalformat.cpp.
|
protected |
Translates a Todo into a VTodo-type VObject and return pointer.
- Parameters
-
todo is a pointer to a valid Todo object.
Definition at line 314 of file vcalformat.cpp.
|
virtual |
Implements KCalCore::CalFormat.
Definition at line 206 of file vcalformat.cpp.
|
virtual |
Implements KCalCore::CalFormat.
Definition at line 200 of file vcalformat.cpp.
|
protected |
Takes a string in YYYYMMDDTHHMMSS format and returns a valid KDateTime.
- Parameters
-
dtStr is a QString containing the date to convert. If this value is invalid, then KDateTime() is returned.
Definition at line 2163 of file vcalformat.cpp.
Takes a string in the YYYYMMDD format and returns a valid QDate.
- Parameters
-
dtStr is a QString containing the date to convert. If this value is invalid, then KDateTime() is returned.
Definition at line 2192 of file vcalformat.cpp.
|
protected |
Takes a KDateTime and returns a string in format YYYYMMDDTHHMMSS.
- Parameters
-
date is the date to format. zulu if true, then shift the date to UTC.
Definition at line 2135 of file vcalformat.cpp.
|
virtual |
|
protected |
Converts a two letter representation of the day (i.e.
MO, TU, WE, etc) and returns a number 0-6 corresponding to that ordinal day of the week.
- Parameters
-
day is the QString containing the two letter day representation.
- See also
- dayFromNum().
Definition at line 2556 of file vcalformat.cpp.
|
protected |
Parse DAYLIGHT tag from vtimezone.
Definition at line 2101 of file vcalformat.cpp.
|
protected |
Parse TZ tag from vtimezone.
Definition at line 2094 of file vcalformat.cpp.
|
protected |
Parse one of the myriad of ISO8601 timezone offset formats, e.g.
+- hh : mm +- hh mm +- hh
- Parameters
-
s string to be parsed. result timezone offset in seconds, if parse succeeded.
- Returns
- Whether the parse succeeded or not.
Definition at line 2203 of file vcalformat.cpp.
|
protected |
Takes a vCalendar tree of VObjects, and puts all of them that have the "event" property into the dictionary, todos in the todo-list, etc.
Definition at line 2265 of file vcalformat.cpp.
Takes a QDate and returns a string in the format YYYYMMDDTHHMMSS.
- Parameters
-
date is the date to format.
Definition at line 2122 of file vcalformat.cpp.
|
protected |
Converts a status string into an Attendee::PartStat.
- Parameters
-
s is a null-terminated character string containing the status to convert.
- Returns
- a valid Attendee::PartStat. If the string provided is empty, null, or the contents are unrecognized, then Attendee::NeedsAction is returned.
Definition at line 2583 of file vcalformat.cpp.
|
virtual |
|
virtual |
Implements KCalCore::CalFormat.
Definition at line 235 of file vcalformat.cpp.
|
protected |
Translates a VObject into a Event and returns a pointer to it.
- Parameters
-
vevent is a pointer to a valid VObject object.
Definition at line 1518 of file vcalformat.cpp.
|
protectedvirtual |
Reimplemented from KCalCore::CalFormat.
Definition at line 2680 of file vcalformat.cpp.
|
protected |
Translates a VObject of the TODO type into an Event.
- Parameters
-
vtodo is a pointer to a valid VObject object.
Definition at line 1029 of file vcalformat.cpp.
|
protected |
Converts an Attendee::PartStat into a QByteArray string.
- Parameters
-
status is the Attendee::PartStat to convert.
- Returns
- a QByteArray containing the status string.
Definition at line 2615 of file vcalformat.cpp.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:36:53 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.