akonadi
#include <specialcollectionshelperjobs_p.h>
Public Member Functions | |
DefaultResourceJob (KCoreConfigSkeleton *settings, QObject *parent=0) | |
~DefaultResourceJob () | |
void | setDefaultResourceOptions (const QVariantMap &options) |
void | setDefaultResourceType (const QString &type) |
void | setIconForTypeMap (const QMap< QByteArray, QString > &map) |
void | setNameForTypeMap (const QMap< QByteArray, QString > &map) |
void | setTypes (const QList< QByteArray > &types) |
Public Member Functions inherited from Akonadi::ResourceScanJob | |
ResourceScanJob (const QString &resourceId, KCoreConfigSkeleton *settings, QObject *parent=0) | |
~ResourceScanJob () | |
QString | resourceId () const |
Akonadi::Collection | rootResourceCollection () const |
void | setResourceId (const QString &resourceId) |
Akonadi::Collection::List | specialCollections () const |
Public Member Functions inherited from Akonadi::Job | |
Job (QObject *parent=0) | |
virtual | ~Job () |
virtual QString | errorString () const |
void | start () |
Protected Member Functions | |
virtual void | doStart () |
virtual void | slotResult (KJob *job) |
Protected Member Functions inherited from Akonadi::Job | |
virtual bool | addSubjob (KJob *job) |
virtual void | doHandleResponse (const QByteArray &tag, const QByteArray &data) |
virtual bool | doKill () |
void | emitWriteFinished () |
virtual bool | removeSubjob (KJob *job) |
Additional Inherited Members | |
Public Types inherited from Akonadi::Job | |
enum | Error { ConnectionFailed = UserDefinedError, ProtocolVersionMismatch, UserCanceled, Unknown, UserError = UserDefinedError + 42 } |
typedef QList< Job * > | List |
Signals inherited from Akonadi::Job | |
void | aboutToStart (Akonadi::Job *job) |
void | writeFinished (Akonadi::Job *job) |
Protected Slots inherited from Akonadi::Job |
Detailed Description
Helper job for SpecialCollectionsRequestJob.
A custom ResourceScanJob for the default local folders resource. This is a maildir resource stored in ~/.local/share/local-mail.
This job does two things that a regular ResourceScanJob does not do: 1) It creates and syncs the resource if it is missing. The resource ID is stored in a config file named specialcollectionsrc. 2) If the resource had to be recreated, but the folders existed on disk before that, it recovers the folders based on name. For instance, it will give a folder named outbox a SpecialCollectionAttribute of type Outbox.
- Since
- 4.4
Definition at line 116 of file specialcollectionshelperjobs_p.h.
Constructor & Destructor Documentation
|
explicit |
Creates a new DefaultResourceJob.
Definition at line 495 of file specialcollectionshelperjobs.cpp.
DefaultResourceJob::~DefaultResourceJob | ( | ) |
Destroys the DefaultResourceJob.
Definition at line 501 of file specialcollectionshelperjobs.cpp.
Member Function Documentation
|
protectedvirtual |
This method must be reimplemented in the concrete jobs.
It will be called after the job has been started and a connection to the Akonadi backend has been established.
Reimplemented from Akonadi::ResourceScanJob.
Definition at line 531 of file specialcollectionshelperjobs.cpp.
void DefaultResourceJob::setDefaultResourceOptions | ( | const QVariantMap & | options | ) |
Sets the configuration options
that shall be applied to the new resource that is created if the requested special collection does not exist yet.
Definition at line 511 of file specialcollectionshelperjobs.cpp.
void DefaultResourceJob::setDefaultResourceType | ( | const QString & | type | ) |
Sets the type
of the resource that shall be created if the requested special collection does not exist yet.
Definition at line 506 of file specialcollectionshelperjobs.cpp.
void DefaultResourceJob::setIconForTypeMap | ( | const QMap< QByteArray, QString > & | map | ) |
Sets the map
of special collection types to icon names.
Definition at line 526 of file specialcollectionshelperjobs.cpp.
void DefaultResourceJob::setNameForTypeMap | ( | const QMap< QByteArray, QString > & | map | ) |
Sets the map
of special collection types to display names.
Definition at line 521 of file specialcollectionshelperjobs.cpp.
void DefaultResourceJob::setTypes | ( | const QList< QByteArray > & | types | ) |
Sets the list of well known special collection types
.
Definition at line 516 of file specialcollectionshelperjobs.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:38:04 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.