Kgapi

tasklistmodifyjob.h
1/*
2 * This file is part of LibKGAPI library
3 *
4 * SPDX-FileCopyrightText: 2013 Daniel Vrátil <dvratil@redhat.com>
5 *
6 * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7 */
8
9#pragma once
10
11#include "kgapitasks_export.h"
12#include "modifyjob.h"
13
14#include <QScopedPointer>
15
16namespace KGAPI2
17{
18
19/**
20 * @brief A job to modify tasklists in user's Google Tasks account.
21 *
22 * @author Daniel Vrátil <dvratil@redhat.com>
23 * @since 2.0
24 */
25class KGAPITASKS_EXPORT TaskListModifyJob : public KGAPI2::ModifyJob
26{
27 Q_OBJECT
28
29public:
30 /**
31 * @brief Constructs a job that will write changes in given @p taskList to
32 * corresponding tasklist in user's Google Tasks account
33 *
34 * @param taskList Tasklist to modify
35 * @param account Account to authenticate the request
36 * @param parent
37 */
38 explicit TaskListModifyJob(const TaskListPtr &taskList, const AccountPtr &account, QObject *parent = nullptr);
39
40 /**
41 * @brief Constructs a job that will write changes in given @p taskLists to
42 * corresponding tasklists in user's Google Tasks account
43 *
44 * @param taskLists Tasklists to modify
45 * @param account Account to authenticate the request
46 * @param parent
47 */
48 explicit TaskListModifyJob(const TaskListsList &taskLists, const AccountPtr &account, QObject *parent = nullptr);
49
50 /**
51 * @brief Destructor
52 */
54
55protected:
56 /**
57 * @brief KGAPI2::Job::start implementation
58 */
59 void start() override;
60
61 /**
62 * @brief KGAPI2::ModifyJob::handleReplyWithItems implementation
63 *
64 * @param reply
65 * @param rawData
66 */
67 ObjectsList handleReplyWithItems(const QNetworkReply *reply, const QByteArray &rawData) override;
68
69private:
70 class Private;
72 friend class Private;
73};
74
75} // namespace KGAPI2
Abstract superclass for all jobs that somehow modify resources on Google.
Definition modifyjob.h:25
A job to modify tasklists in user's Google Tasks account.
~TaskListModifyJob() override
Destructor.
Q_SCRIPTABLE Q_NOREPLY void start()
A job to fetch a single map tile described by a StaticMapUrl.
Definition blog.h:16
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:17:41 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.