Kgapi

taskcreatejob.h
1 /*
2  * This file is part of LibKGAPI library
3  *
4  * SPDX-FileCopyrightText: 2013 Daniel Vrátil <[email protected]>
5  *
6  * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
7  */
8 
9 #ifndef LIBKGAPI2_TASKCREATEJOB_H
10 #define LIBKGAPI2_TASKCREATEJOB_H
11 
12 #include "createjob.h"
13 #include "kgapitasks_export.h"
14 
15 #include <QScopedPointer>
16 
17 namespace KGAPI2 {
18 
25 class KGAPITASKS_EXPORT TaskCreateJob : public KGAPI2::CreateJob
26 {
27  Q_OBJECT
28 
40  Q_PROPERTY(QString parentItem READ parentItem WRITE setParentItem)
41 
42 
50  Q_PROPERTY(QString previous READ previous WRITE setPrevious)
51 
52  public:
53 
63  explicit TaskCreateJob(const TaskPtr& task, const QString &taskListId,
64  const AccountPtr &account, QObject* parent = nullptr);
65 
75  explicit TaskCreateJob(const TasksList& tasks, const QString &taskListId,
76  const AccountPtr &account, QObject* parent = nullptr);
77 
81  ~TaskCreateJob() override;
82 
88  void setParentItem(const QString &parentId);
89 
93  QString parentItem() const;
94 
101  void setPrevious(const QString &previousId);
102 
107  QString previous() const;
108 
109  protected:
110  void start() override;
111  ObjectsList handleReplyWithItems(const QNetworkReply *reply, const QByteArray& rawData) override;
112 
113  private:
114  class Private;
115  QScopedPointer<Private> const d;
116  friend class Private;
117 };
118 
119 } // namespace KGAPI2
120 
121 #endif // KGAPI2_TASKCREATEJOB_H
Abstract superclass for all jobs that create new objects on the server.
Definition: createjob.h:25
A job to fetch a single map tile described by a StaticMapUrl.
Definition: blog.h:16
A job to create one or more new tasks in Google Tasks.
Definition: taskcreatejob.h:25
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Thu Sep 17 2020 23:09:50 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.