• Skip to content
  • Skip to link menu
Brand

API Documentation

  1. KDE API Reference
  2. KDE PIM
  3. Akonadi
  • KDE Home
  • Contact Us

Quick Links

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

Class Picker

About

PIM Storage Framework

Maintainer
Daniel Vrátil
Supported platforms
Linux
Community
IRC: #akonadi on Freenode
Mailing list: kde-pim
Use with CMake
find_package(KF5AkonadiCore)
target_link_libraries(yourapp KF5::AkonadiCore)
Use with QMake
QT += AkonadiCore 
Clone
git clone git://anongit.kde.org/akonadi.git
Browse source
Akonadi on cgit.kde.org

Akonadi

  • kde
  • pim
  • akonadi
  • src
  • core
  • jobs
collectionfetchjob.h
1 /*
2  Copyright (c) 2006 - 2007 Volker Krause <[email protected]>
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_COLLECTIONFETCHJOB_H
21 #define AKONADI_COLLECTIONFETCHJOB_H
22 
23 #include "akonadicore_export.h"
24 #include "collection.h"
25 #include "job.h"
26 
27 namespace Akonadi
28 {
29 
30 class CollectionFetchScope;
31 class CollectionFetchJobPrivate;
32 
54 class AKONADICORE_EXPORT CollectionFetchJob : public Job
55 {
56  Q_OBJECT
57 
58 public:
62  enum Type {
63  Base,
64  FirstLevel,
65  Recursive,
66  NonOverlappingRoots
67  };
68 
85  explicit CollectionFetchJob(const Collection &collection, Type type = FirstLevel, QObject *parent = nullptr);
86 
102  explicit CollectionFetchJob(const Collection::List &collections, QObject *parent = nullptr);
103 
122  CollectionFetchJob(const Collection::List &collections, Type type, QObject *parent = nullptr);
123 
131  explicit CollectionFetchJob(const QList<Collection::Id> &collections, Type type = Base, QObject *parent = nullptr);
132 
136  ~CollectionFetchJob() override;
137 
141  Q_REQUIRED_RESULT Collection::List collections() const;
142 
155  void setFetchScope(const CollectionFetchScope &fetchScope);
156 
170  Q_REQUIRED_RESULT CollectionFetchScope &fetchScope();
171 
172 Q_SIGNALS:
178  void collectionsReceived(const Akonadi::Collection::List &collections);
179 
180 protected:
181  void doStart() override;
182  bool doHandleResponse(qint64 tag, const Protocol::CommandPtr &response) override;
183 
184 protected Q_SLOTS:
185  //@cond PRIVATE
186  void slotResult(KJob *job) override;
187  //@endcond
188 
189 private:
190  Q_DECLARE_PRIVATE(CollectionFetchJob)
191 
192  //@cond PRIVATE
193  Q_PRIVATE_SLOT(d_func(), void timeout())
194  Q_PRIVATE_SLOT(d_func(), void subJobCollectionReceived(const Akonadi::Collection::List &))
195  //@endcond
196 };
197 
198 }
199 
200 #endif
Akonadi::CollectionFetchScope
Specifies which parts of a collection should be fetched from the Akonadi storage. ...
Definition: collectionfetchscope.h:70
Akonadi::CollectionFetchJob::Type
Type
Describes the type of fetch depth.
Definition: collectionfetchjob.h:62
Akonadi::CollectionFetchJob::FirstLevel
Only list direct sub-collections of the base collection.
Definition: collectionfetchjob.h:64
Akonadi::Collection
Represents a collection of PIM items.
Definition: collection.h:76
Akonadi::CollectionFetchJob
Job that fetches collections from the Akonadi storage.
Definition: collectionfetchjob.h:54
Akonadi::Job
Base class for all actions in the Akonadi storage.
Definition: job.h:93
Akonadi::CollectionFetchJob::Base
Only fetch the base collection.
Definition: collectionfetchjob.h:63
QSharedPointer
QObject
QList
QVector< Collection >
Akonadi
KJob
Akonadi::CollectionFetchJob::Recursive
List all sub-collections.
Definition: collectionfetchjob.h:65
This file is part of the KDE documentation.
Documentation copyright © 1996-2019 The KDE developers.
Generated on Wed Dec 11 2019 07:11:16 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

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