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

mailcommon

  • MailCommon
  • Kernel
Signals | Public Member Functions | Static Public Member Functions | List of all members
MailCommon::Kernel Class Reference

#include <mailkernel.h>

Inheritance diagram for MailCommon::Kernel:
Inheritance graph
[legend]

Signals

void requestConfigSync ()
 
void requestSystemTrayUpdate ()
 

Public Member Functions

virtual ~Kernel ()
 
Akonadi::Collection collectionFromId (const Akonadi::Collection::Id &id) const
 
Akonadi::Collection draftsCollectionFolder ()
 
void emergencyExit (const QString &reason)
 
IFilter * filterIf () const
 
bool folderIsDraftOrOutbox (const Akonadi::Collection &collection)
 
bool folderIsDrafts (const Akonadi::Collection &)
 
bool folderIsSentMailFolder (const Akonadi::Collection &)
 
bool folderIsTemplates (const Akonadi::Collection &collection)
 
bool folderIsTrash (const Akonadi::Collection &collection)
 
Akonadi::Collection inboxCollectionFolder ()
 
void initFolders ()
 
bool isMainFolderCollection (const Akonadi::Collection &col)
 
bool isSystemFolderCollection (const Akonadi::Collection &col)
 
IKernel * kernelIf () const
 
bool kernelIsRegistered () const
 
Akonadi::Collection outboxCollectionFolder ()
 
void registerFilterIf (IFilter *filterIf)
 
void registerKernelIf (IKernel *kernelIf)
 
void registerSettingsIf (ISettings *settingsIf)
 
Akonadi::Collection sentCollectionFolder ()
 
ISettings * settingsIf () const
 
Akonadi::Collection templatesCollectionFolder ()
 
Akonadi::Collection trashCollectionFolder ()
 
Akonadi::Collection trashCollectionFromResource (const Akonadi::Collection &col)
 

Static Public Member Functions

static bool folderIsInbox (const Akonadi::Collection &, bool withoutPop3InboxSetting=false)
 
static Kernel * self ()
 

Detailed Description

Deals with common mail application related operations.

The required interfaces MUST be registered before using it! Be careful when using in multi-threaded applications, as Kernel is a QObject singleton, created in the main thread, thus event handling for Kernel::self() will happen in the main thread.

Definition at line 42 of file mailkernel.h.

Constructor & Destructor Documentation

MailCommon::Kernel::~Kernel ( )
virtual

Definition at line 66 of file mailkernel.cpp.

Member Function Documentation

Akonadi::Collection MailCommon::Kernel::collectionFromId ( const Akonadi::Collection::Id &  id) const

Returns the collection associated with the given id, or an invalid collection if not found.

The EntityTreeModel of the kernel is searched for the collection. Since the ETM is loaded async, this method will not find the collection right after startup, when the ETM is not yet fully loaded.

Definition at line 76 of file mailkernel.cpp.

Akonadi::Collection MailCommon::Kernel::draftsCollectionFolder ( )

Definition at line 113 of file mailkernel.cpp.

void MailCommon::Kernel::emergencyExit ( const QString &  reason)

Definition at line 211 of file mailkernel.cpp.

IFilter* MailCommon::Kernel::filterIf ( ) const
inline

Definition at line 98 of file mailkernel.h.

bool MailCommon::Kernel::folderIsDraftOrOutbox ( const Akonadi::Collection &  collection)

Returns true if the folder is either the outbox or one of the drafts-folders.

Definition at line 234 of file mailkernel.cpp.

bool MailCommon::Kernel::folderIsDrafts ( const Akonadi::Collection &  col)

Definition at line 243 of file mailkernel.cpp.

bool MailCommon::Kernel::folderIsInbox ( const Akonadi::Collection &  collection,
bool  withoutPop3InboxSetting = false 
)
static

Definition at line 335 of file mailkernel.cpp.

bool MailCommon::Kernel::folderIsSentMailFolder ( const Akonadi::Collection &  col)

Returns true if the folder is one of the sent-mail folders.

Definition at line 313 of file mailkernel.cpp.

bool MailCommon::Kernel::folderIsTemplates ( const Akonadi::Collection &  collection)

Definition at line 265 of file mailkernel.cpp.

bool MailCommon::Kernel::folderIsTrash ( const Akonadi::Collection &  collection)

Returns true if the folder is a trash folder.

When calling this too early (before the SpecialMailCollectionsDiscoveryJob from initFolders finishes), it will say false erroneously. However you can connect to SpecialMailCollections::collectionsChanged to react on dynamic changes and call this again.

Definition at line 297 of file mailkernel.cpp.

Akonadi::Collection MailCommon::Kernel::inboxCollectionFolder ( )

Definition at line 92 of file mailkernel.cpp.

void MailCommon::Kernel::initFolders ( )

Definition at line 143 of file mailkernel.cpp.

bool MailCommon::Kernel::isMainFolderCollection ( const Akonadi::Collection &  col)

Returns true if this folder is the inbox on the local disk.

Definition at line 137 of file mailkernel.cpp.

bool MailCommon::Kernel::isSystemFolderCollection ( const Akonadi::Collection &  col)

Definition at line 127 of file mailkernel.cpp.

IKernel* MailCommon::Kernel::kernelIf ( ) const
inline

Definition at line 66 of file mailkernel.h.

bool MailCommon::Kernel::kernelIsRegistered ( ) const
inline

Definition at line 61 of file mailkernel.h.

Akonadi::Collection MailCommon::Kernel::outboxCollectionFolder ( )

Definition at line 99 of file mailkernel.cpp.

void MailCommon::Kernel::registerFilterIf ( IFilter *  filterIf)
inline

Registers the interface dealing with mail settings.

This function MUST be called with a valid interface pointer, before any Kernel::self() method is used. The pointer ownership will not be transferred to Kernel.

Definition at line 93 of file mailkernel.h.

void MailCommon::Kernel::registerKernelIf ( IKernel *  kernelIf)
inline

Registers the interface dealing with main mail functionality.

This function MUST be called with a valid interface pointer, before any Kernel::self() method is used. The pointer ownership will not be transferred to Kernel.

Definition at line 56 of file mailkernel.h.

void MailCommon::Kernel::registerSettingsIf ( ISettings *  settingsIf)
inline

Registers the interface dealing with mail settings.

This function MUST be called with a valid interface pointer, before any Kernel::self() method is used. The pointer ownership will not be transferred to Kernel.

Definition at line 77 of file mailkernel.h.

void MailCommon::Kernel::requestConfigSync ( )
signal
void MailCommon::Kernel::requestSystemTrayUpdate ( )
signal
Kernel * MailCommon::Kernel::self ( )
static

Definition at line 71 of file mailkernel.cpp.

Akonadi::Collection MailCommon::Kernel::sentCollectionFolder ( )

Definition at line 106 of file mailkernel.cpp.

ISettings* MailCommon::Kernel::settingsIf ( ) const
inline

Definition at line 82 of file mailkernel.h.

Akonadi::Collection MailCommon::Kernel::templatesCollectionFolder ( )

Definition at line 120 of file mailkernel.cpp.

Akonadi::Collection MailCommon::Kernel::trashCollectionFolder ( )

Definition at line 85 of file mailkernel.cpp.

Akonadi::Collection MailCommon::Kernel::trashCollectionFromResource ( const Akonadi::Collection &  col)

Returns the trash folder for the resource which col belongs to.

When calling this too early (before the SpecialMailCollectionsDiscoveryJob from initFolders finishes), it will return an invalid collection erroneously. However you can connect to SpecialMailCollections::collectionsChanged to react on dynamic changes and call this again.

Definition at line 287 of file mailkernel.cpp.


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

KDE's Doxygen guidelines are available online.

mailcommon

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

kdepim API Reference

Skip menu "kdepim API Reference"
  • akonadi_next
  • akregator
  • blogilo
  • calendarsupport
  • console
  •   kabcclient
  •   konsolekalendar
  • kaddressbook
  • kalarm
  •   lib
  • kdgantt2
  • kjots
  • kleopatra
  • kmail
  • knode
  • knotes
  • kontact
  • korgac
  • korganizer
  • ktimetracker
  • libkdepim
  • libkleo
  • libkpgp
  • mailcommon
  • messagelist
  • messageviewer

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