File indexing completed on 2024-05-12 05:22:17
0001 /* 0002 * This file is part of LibKGAPI library 0003 * 0004 * SPDX-FileCopyrightText: 2013 Daniel Vrátil <dvratil@redhat.com> 0005 * 0006 * SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0007 */ 0008 0009 #pragma once 0010 0011 #include "createjob.h" 0012 #include "kgapidrive_export.h" 0013 0014 #include <QStringList> 0015 0016 namespace KGAPI2 0017 { 0018 0019 namespace Drive 0020 { 0021 0022 class KGAPIDRIVE_EXPORT ChildReferenceCreateJob : public KGAPI2::CreateJob 0023 { 0024 Q_OBJECT 0025 0026 public: 0027 explicit ChildReferenceCreateJob(const QString &folderId, const QString &childId, const AccountPtr &account, QObject *parent = nullptr); 0028 explicit ChildReferenceCreateJob(const QString &folderId, const QStringList &childrenIds, const AccountPtr &account, QObject *parent = nullptr); 0029 explicit ChildReferenceCreateJob(const QString &folderId, const ChildReferencePtr &reference, const AccountPtr &account, QObject *parent = nullptr); 0030 explicit ChildReferenceCreateJob(const QString &folderId, const ChildReferencesList &references, const AccountPtr &account, QObject *parent = nullptr); 0031 ~ChildReferenceCreateJob() override; 0032 0033 /** 0034 * @brief Whether the request supports both My Drives and shared drives. 0035 * 0036 * Set to true by default as LibKGAPI supports Team Drives. 0037 * 0038 * @deprecated This parameter will only be effective until June 1, 2020. Afterwards all applications 0039 * are assumed to support shared drives. 0040 */ 0041 KGAPIDRIVE_DEPRECATED bool supportsAllDrives() const; 0042 0043 /** 0044 * @brief Sets whether the request supports both My Drives and shared drives. 0045 * 0046 * Set to true by default as LibKGAPI supports Team Drives. 0047 * 0048 * @deprecated This parameter will only be effective until June 1, 2020. Afterwards all applications 0049 * are assumed to support shared drives. 0050 */ 0051 KGAPIDRIVE_DEPRECATED void setSupportsAllDrives(bool supportsAllDrives); 0052 0053 protected: 0054 void start() override; 0055 ObjectsList handleReplyWithItems(const QNetworkReply *reply, const QByteArray &rawData) override; 0056 0057 private: 0058 class Private; 0059 Private *const d; 0060 friend class Private; 0061 }; 0062 0063 } // namespace Drive 0064 0065 } // namespace KGAPI2