Akonadi

tagsync.h
1/*
2 SPDX-FileCopyrightText: 2014 Christian Mollekopf <mollekopf@kolabsys.com>
3
4 SPDX-License-Identifier: LGPL-2.0-or-later
5*/
6#pragma once
7
8#include "akonadicore_export.h"
9
10#include "item.h"
11#include "jobs/job.h"
12#include "tag.h"
13
14namespace Akonadi
15{
16class AKONADICORE_EXPORT TagSync : public Akonadi::Job
17{
18 Q_OBJECT
19public:
20 explicit TagSync(QObject *parent = nullptr);
21 ~TagSync() override;
22
23 void setFullTagList(const Akonadi::Tag::List &tags);
24 void setTagMembers(const QHash<QString, Akonadi::Item::List> &ridMemberMap);
25
26protected:
27 void doStart() override;
28
29private Q_SLOTS:
30 void onLocalTagFetchDone(KJob *job);
31 void onCreateTagDone(KJob *job);
32 void onTagItemsFetchDone(KJob *job);
33 void onJobDone(KJob *job);
34 void slotResult(KJob *job) override;
35
36private:
37 void diffTags();
38 void checkDone();
39
40private:
41 Akonadi::Tag::List mRemoteTags;
42 Akonadi::Tag::List mLocalTags;
43 bool mDeliveryDone = false;
44 bool mTagMembersDeliveryDone = false;
45 bool mLocalTagsFetched = false;
47};
48
49}
Base class for all actions in the Akonadi storage.
Definition job.h:81
Helper integration between Akonadi and Qt.
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:08:30 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.