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

akonadi

  • Akonadi
  • ITIPHandlerHelper
Public Types | Signals | Public Member Functions | List of all members
Akonadi::ITIPHandlerHelper Class Reference

#include <itiphandlerhelper_p.h>

Inherits QObject.

Public Types

enum  Action { ActionAsk, ActionSendMessage, ActionDontSendMessage }
 
enum  SendResult {
  ResultCanceled, ResultFailKeepUpdate, ResultFailAbortUpdate, ResultNoSendingNeeded,
  ResultError, ResultSuccess
}
 

Signals

void finished (Akonadi::ITIPHandlerHelper::SendResult result, const QString &errorMessage)
 

Public Member Functions

 ITIPHandlerHelper (QWidget *parent=0)
 
void calendarJobFinished (bool success, const QString &errorString)
 
bool handleIncidenceAboutToBeModified (const KCalCore::Incidence::Ptr &incidence)
 
ITIPHandlerHelper::SendResult sendCounterProposal (const KCalCore::Incidence::Ptr &oldIncidence, const KCalCore::Incidence::Ptr &newIncidence)
 
ITIPHandlerHelper::SendResult sendIncidenceCreatedMessage (KCalCore::iTIPMethod method, const KCalCore::Incidence::Ptr &incidence)
 
ITIPHandlerHelper::SendResult sendIncidenceDeletedMessage (KCalCore::iTIPMethod method, const KCalCore::Incidence::Ptr &incidence)
 
ITIPHandlerHelper::SendResult sendIncidenceModifiedMessage (KCalCore::iTIPMethod method, const KCalCore::Incidence::Ptr &incidence, bool attendeeStatusChanged)
 
void setDefaultAction (Action action)
 
void setDialogParent (QWidget *parent)
 

Detailed Description

This class handles sending of invitations to attendees when Incidences (e.g.

events or todos) are created/modified/deleted.

There are two scenarios: o "we" are the organizer, where "we" means any of the identities or mail addresses known to Kontact/PIM. If there are attendees, we need to mail them all, even if one or more of them are also "us". Otherwise there would be no way to invite a resource or our boss, other identities we also manage. o "we: are not the organizer, which means we changed the completion status of a todo, or we changed our attendee status from, say, tentative to accepted. In both cases we only mail the organizer. All other changes bring us out of sync with the organizer, so we won't mail, if the user insists on applying them.

NOTE: Currently only events and todos are support, meaning Incidence::type() should either return "Event" or "Todo"

Definition at line 67 of file itiphandlerhelper_p.h.

Member Enumeration Documentation

enum Akonadi::ITIPHandlerHelper::SendResult
Enumerator
ResultCanceled 

Sending was canceled by the user, meaning there are local changes of which other attendees are not aware.

ResultFailKeepUpdate 

Sending failed, the changes to the incidence must be kept.

ResultFailAbortUpdate 

Sending failed, the changes to the incidence must be undone.

ResultNoSendingNeeded 

In some cases it is not needed to send an invitation (e.g.

when we are the only attendee)

ResultError 

An unexpected error occurred.

ResultSuccess 

The invitation was sent to all attendees.

Definition at line 74 of file itiphandlerhelper_p.h.

Member Function Documentation

bool Akonadi::ITIPHandlerHelper::handleIncidenceAboutToBeModified ( const KCalCore::Incidence::Ptr &  incidence)

Checks if the incidence should really be modified.

If the user is not the organizer of this incidence, he will be asked if he really wants to proceed.

Only create the ItemModifyJob if this method returns true.

Parameters
incidenceThe modified incidence. It may not be null.
ITIPHandlerHelper::SendResult Akonadi::ITIPHandlerHelper::sendCounterProposal ( const KCalCore::Incidence::Ptr &  oldIncidence,
const KCalCore::Incidence::Ptr &  newIncidence 
)

Send counter proposal message.

Parameters
oldIncidenceThe original event provided in the invitations.
newIncidenceThe new event as edited by the user.
ITIPHandlerHelper::SendResult Akonadi::ITIPHandlerHelper::sendIncidenceCreatedMessage ( KCalCore::iTIPMethod  method,
const KCalCore::Incidence::Ptr &  incidence 
)

Handles sending of invitations for newly created incidences.

This method asserts that we (as in any of the identities or mail addresses known to Kontact/PIM) are the organizer.

Parameters
incidenceThe new incidence.
ITIPHandlerHelper::SendResult Akonadi::ITIPHandlerHelper::sendIncidenceDeletedMessage ( KCalCore::iTIPMethod  method,
const KCalCore::Incidence::Ptr &  incidence 
)

Handles sending of ivitations for deleted incidences.

Parameters
incidenceThe deleted incidence.
ITIPHandlerHelper::SendResult Akonadi::ITIPHandlerHelper::sendIncidenceModifiedMessage ( KCalCore::iTIPMethod  method,
const KCalCore::Incidence::Ptr &  incidence,
bool  attendeeStatusChanged 
)

Handles sending of invitations for modified incidences.

Parameters
incidenceThe modified incidence.
attendeeStatusChangedif true and method is #iTIPRequest ask the user whether to send a status update as well
void Akonadi::ITIPHandlerHelper::setDefaultAction ( Action  action)

When an Incidence is created/modified/deleted the user can choose to send an ICal message to the other participants.

By default the user will be asked if he wants to send a message to other participants. In some cases it is preferably though to not bother the user with this question. This method allows to change the default behavior. This method applies to the sendIncidence*Message() methods.

Parameters
actionthe action to set as default
void Akonadi::ITIPHandlerHelper::setDialogParent ( QWidget *  parent)

Before an invitation is sent the user is asked for confirmation by means of an dialog.

Parameters
parentThe parent widget used for the dialogs.

The documentation for this class was generated from the following file:
  • itiphandlerhelper_p.h
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:29 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

akonadi

Skip menu "akonadi"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Modules
  • Related Pages

kdepimlibs API Reference

Skip menu "kdepimlibs API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kldap
  • kmbox
  • kmime
  • kpimidentities
  • kpimtextedit
  • kresources
  • ktnef
  • kxmlrpcclient
  • microblog

Search



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