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

akonadi

  • sources
  • kde-4.12
  • kdepimlibs
  • akonadi
specialcollectionsrequestjob.h
1 /*
2  Copyright (c) 2009 Constantin Berzan <exit3219@gmail.com>
3 
4  This library is free software; you can redistribute it and/or modify it
5  under the terms of the GNU Library General Public License as published by
6  the Free Software Foundation; either version 2 of the License, or (at your
7  option) any later version.
8 
9  This library is distributed in the hope that it will be useful, but WITHOUT
10  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11  FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
12  License for more details.
13 
14  You should have received a copy of the GNU Library General Public License
15  along with this library; see the file COPYING.LIB. If not, write to the
16  Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
17  02110-1301, USA.
18 */
19 
20 #ifndef AKONADI_SPECIALCOLLECTIONSREQUESTJOB_H
21 #define AKONADI_SPECIALCOLLECTIONSREQUESTJOB_H
22 
23 #include "akonadi_export.h"
24 
25 #include <akonadi/collection.h>
26 #include <akonadi/specialcollections.h>
27 #include <akonadi/transactionsequence.h>
28 
29 #include <QtCore/QVariant>
30 
31 namespace Akonadi {
32 
33 class SpecialCollectionsRequestJobPrivate;
34 
54 class AKONADI_EXPORT SpecialCollectionsRequestJob : public TransactionSequence
55 {
56  Q_OBJECT
57 
58  public:
59 
63  ~SpecialCollectionsRequestJob();
64 
68  void requestDefaultCollection( const QByteArray &type );
69 
73  void requestCollection( const QByteArray &type, const AgentInstance &instance );
74 
78  Collection collection() const;
79 
80  protected:
87  explicit SpecialCollectionsRequestJob( SpecialCollections *collections, QObject *parent = 0 );
88 
93  void setDefaultResourceType( const QString &type );
94 
99  void setDefaultResourceOptions( const QVariantMap &options );
100 
104  void setTypes( const QList<QByteArray> &types );
105 
109  void setNameForTypeMap( const QMap<QByteArray, QString> &map );
110 
114  void setIconForTypeMap( const QMap<QByteArray, QString> &map );
115 
116  /* reimpl */
117  virtual void doStart();
118  /* reimpl */
119  virtual void slotResult( KJob *job );
120 
121  private:
122  //@cond PRIVATE
123  friend class SpecialCollectionsRequestJobPrivate;
124  friend class DefaultResourceJobPrivate;
125 
126  SpecialCollectionsRequestJobPrivate *const d;
127 
128  Q_PRIVATE_SLOT( d, void lockResult( KJob* ) )
129  Q_PRIVATE_SLOT( d, void releaseLock() )
130  Q_PRIVATE_SLOT( d, void resourceScanResult( KJob* ) )
131  Q_PRIVATE_SLOT( d, void collectionCreateResult( KJob* ) )
132  //@endcond
133 };
134 
135 } // namespace Akonadi
136 
137 #endif // AKONADI_SPECIALCOLLECTIONSREQUESTJOB_H
Akonadi::SpecialCollections
An interface to special collections.
Definition: specialcollections.h:65
Akonadi::releaseLock
bool AKONADI_TESTS_EXPORT releaseLock()
Releases the SpecialCollectionsRequestJob lock that was obtained through GetLockJob.
Definition: specialcollectionshelperjobs.cpp:645
Akonadi::Collection
Represents a collection of PIM items.
Definition: collection.h:75
Akonadi::TransactionSequence
Base class for jobs that need to run a sequence of sub-jobs in a transaction.
Definition: transactionsequence.h:69
Akonadi::AgentInstance
A representation of an agent instance.
Definition: agentinstance.h:62
Akonadi::SpecialCollectionsRequestJob
A job to request SpecialCollections.
Definition: specialcollectionsrequestjob.h:54
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:28 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