libkcal

KCal::CalHelper Namespace Reference

Functions

bool isMyKolabIncidence (Calendar *calendar, Incidence *incidence)
bool isMyCalendarIncidence (Calendar *calendar, Incidence *incidence)
IncidencefindMyCalendarIncidenceByUid (Calendar *calendar, const TQString &uid)
bool usingGroupware (Calendar *calendar)
bool hasMyWritableEventsFolders (const TQString &family)
ResourceCalendarincResourceCalendar (Calendar *calendar, Incidence *incidence)
TQPair< ResourceCalendar
*, TQString > 
incSubResourceCalendar (Calendar *calendar, Incidence *incidence)

Detailed Description

Provides methods for making decisions about calendar data.


Function Documentation

Incidence * KCal::CalHelper::findMyCalendarIncidenceByUid ( Calendar calendar,
const TQString &  uid 
)

Searches for the specified Incidence by UID, returning an Incidence pointer if and only if the found Incidence is owned by the user.

Parameters:
calendaris a pointer to a valid Calendar object.
Uidis a TQString containing an Incidence UID.
Returns:
a pointer to the Incidence found; 0 if the Incidence is not found or the Incidence is found but is not owned by the user.

Definition at line 60 of file calhelper.cpp.

bool KCal::CalHelper::hasMyWritableEventsFolders ( const TQString &  family)

Determines if the Calendar has any writable folders with Events content that are owned by me.

Parameters:
familyis the resource family name or "calendar" if empty.
Returns:
true if the any such writable folders are found; false otherwise.
Since:
4.5

Definition at line 100 of file calhelper.cpp.

Returns the ResourceCalendar where the Incidence is stored, if any.

Parameters:
calendaris a pointer to a valid Calendar object.
incidenceis a pointer to an Incidence object.
Returns:
a pointer to the ResourceCalendar where the Incidence is stored; else 0 if none can be found.
Since:
4.5

Definition at line 139 of file calhelper.cpp.

TQPair< ResourceCalendar *, TQString > KCal::CalHelper::incSubResourceCalendar ( Calendar calendar,
Incidence incidence 
)

Returns the (ResourceCalendar, SubResourceCalendar) pair where the Incidence is stored, if any.

Parameters:
calendaris a pointer to a valid Calendar object.
incidenceis a pointer to an Incidence object.
Returns:
a TQPair containing a pointer to the Incidence's ResourceCalendar in the 'first' element of the TQPair and the SubResourceCalendar in the 'second' element.
Note:
many resource types do not support subresources, so the 'second' element will be an empty TQString in those situations.
Since:
4.5

Definition at line 149 of file calhelper.cpp.

bool KCal::CalHelper::isMyCalendarIncidence ( Calendar calendar,
Incidence incidence 
)

Determine if the specified incidence is likely owned by the the user, independent of the Resource type.

Parameters:
calendaris a pointer to a valid Calendar object.
incidenceis a pointer to an Incidence object.
Returns:
true if it is likely that the specified incidence belongs to the user; false otherwise.

Definition at line 55 of file calhelper.cpp.

bool KCal::CalHelper::isMyKolabIncidence ( Calendar calendar,
Incidence incidence 
)

Determine if the specified incidence is likely a Kolab incidence owned by the the user.

Parameters:
calendaris a pointer to a valid Calendar object.
incidenceis a pointer to an Incidence object.
Returns:
true if it is likely that the specified incidence belongs to the user in their Kolab resource; false otherwise.

Definition at line 37 of file calhelper.cpp.

Determines if the Calendar is using a Groupware resource type.

Parameters:
calendaris a pointer to a valid Calendar object.
Returns:
true if the Calendar is using a known Groupware resource type; false otherwise.
Since:
4.4

Definition at line 82 of file calhelper.cpp.