Kgapi

permissiondeletejob.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 "deletejob.h"
12#include "kgapidrive_export.h"
13
14#include <QStringList>
15
16namespace KGAPI2
17{
18
19namespace Drive
20{
21
22class KGAPIDRIVE_EXPORT PermissionDeleteJob : public KGAPI2::DeleteJob
23{
24 Q_OBJECT
25
26public:
27 explicit PermissionDeleteJob(const QString &fileId, const PermissionPtr &permission, const AccountPtr &account, QObject *parent = nullptr);
28 explicit PermissionDeleteJob(const QString &fileId, const QString &permissionId, const AccountPtr &account, QObject *parent = nullptr);
29 explicit PermissionDeleteJob(const QString &fileId, const PermissionsList &permissions, const AccountPtr &account, QObject *parent = nullptr);
30 explicit PermissionDeleteJob(const QString &fileId, const QStringList &permissionsIds, const AccountPtr &account, QObject *parent = nullptr);
31 ~PermissionDeleteJob() override;
32
33 /**
34 * @brief Whether the request supports both My Drives and shared drives.
35 *
36 * Set to true by default as LibKGAPI supports Team Drives.
37 *
38 * @deprecated This parameter will only be effective until June 1, 2020. Afterwards all applications
39 * are assumed to support shared drives.
40 */
41 KGAPIDRIVE_DEPRECATED bool supportsAllDrives() const;
42
43 /**
44 * @brief Sets whether the request supports both My Drives and shared drives.
45 *
46 * Set to true by default as LibKGAPI supports Team Drives.
47 *
48 * @deprecated This parameter will only be effective until June 1, 2020. Afterwards all applications
49 * are assumed to support shared drives.
50 */
51 KGAPIDRIVE_DEPRECATED void setSupportsAllDrives(bool supportsAllDrives);
52
53 /**
54 * @brief Issue the request as a domain administrator; if set to true,
55 * then the requester will be granted access if the file ID parameter refers
56 * to a shared drive and the requester is an administrator of the domain to
57 * which the shared drive belongs. (Default: false)
58 */
59 bool useDomainAdminAccess() const;
60
61 /**
62 * @brief Sets to issue the request as a domain administrator; if set to true,
63 * then the requester will be granted access if the file ID parameter refers
64 * to a shared drive and the requester is an administrator of the domain to
65 * which the shared drive belongs. (Default: false)
66 */
67 void setUseDomainAdminAccess(bool useDomainAdminAccess);
68
69protected:
70 void start() override;
71
72private:
73 class Private;
75 friend class Private;
76};
77
78} // namespace Drive
79
80} // namespace KGAPI2
Abstract superclass for all jobs that delete resources from Google.
Definition deletejob.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:52 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.