Kgapi

commentapprovejob.h
1/*
2 * SPDX-FileCopyrightText: 2014 Daniel Vrátil <dvratil@redhat.com>
3 *
4 * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5 */
6
7#pragma once
8
9#include "kgapiblogger_export.h"
10#include "modifyjob.h"
11
12namespace KGAPI2
13{
14namespace Blogger
15{
16
17class KGAPIBLOGGER_EXPORT CommentApproveJob : public KGAPI2::ModifyJob
18{
19 Q_OBJECT
20
21public:
22 enum ApprovalAction { Approve, MarkAsSpam };
23 explicit CommentApproveJob(const QString &blogId,
24 const QString &postId,
25 const QString &commentId,
26 ApprovalAction action,
27 const AccountPtr &account,
28 QObject *parent = nullptr);
29 explicit CommentApproveJob(const CommentPtr &comment, ApprovalAction action, const AccountPtr &account, QObject *parent = nullptr);
30 ~CommentApproveJob() override;
31
32protected:
33 void start() override;
34 ObjectsList handleReplyWithItems(const QNetworkReply *reply, const QByteArray &rawData) override;
35
36private:
37 class Private;
38 Private *const d;
39 friend class Private;
40};
41
42} // namespace Blogger
43} // namespace KGAPI2
Abstract superclass for all jobs that somehow modify resources on Google.
Definition modifyjob.h:25
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 Tue Mar 26 2024 11:19:51 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.