Changeset View
Changeset View
Standalone View
Standalone View
src/drive/drivesmodifyjob.h
- This file was copied from src/drive/teamdrivemodifyjob.h.
Show All 15 Lines | |||||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
17 | * GNU Lesser General Public License for more details. | 17 | * GNU Lesser General Public License for more details. | ||
18 | * | 18 | * | ||
19 | * You should have received a copy of the GNU Lesser General Public | 19 | * You should have received a copy of the GNU Lesser General Public | ||
20 | * License along with this library. If not, see <https://www.gnu.org/licenses/>. | 20 | * License along with this library. If not, see <https://www.gnu.org/licenses/>. | ||
21 | */ | 21 | */ | ||
22 | 22 | | |||
23 | 23 | | |||
24 | #ifndef KGAPI2_DRIVETEAMDRIVEMODIFYJOB_H | 24 | #ifndef KGAPI2_DRIVEDRIVESMODIFYJOB_H | ||
25 | #define KGAPI2_DRIVETEAMDRIVEMODIFYJOB_H | 25 | #define KGAPI2_DRIVEDRIVESMODIFYJOB_H | ||
26 | 26 | | |||
27 | #include "modifyjob.h" | 27 | #include "modifyjob.h" | ||
28 | #include "kgapidrive_export.h" | 28 | #include "kgapidrive_export.h" | ||
29 | 29 | | |||
30 | namespace KGAPI2 | 30 | namespace KGAPI2 | ||
31 | { | 31 | { | ||
32 | 32 | | |||
33 | namespace Drive | 33 | namespace Drive | ||
34 | { | 34 | { | ||
35 | 35 | | |||
36 | class KGAPIDRIVE_EXPORT TeamdriveModifyJob : public KGAPI2::ModifyJob | 36 | class KGAPIDRIVE_EXPORT DrivesModifyJob : public KGAPI2::ModifyJob | ||
37 | { | 37 | { | ||
38 | Q_OBJECT | 38 | Q_OBJECT | ||
39 | 39 | | |||
40 | /** | ||||
41 | * Issue the request as a domain administrator; if set to true, then all | ||||
42 | * shared Drives of the domain in which the requester is an administrator | ||||
43 | * are returned. | ||||
44 | * | ||||
45 | * Default value if missing is false. | ||||
46 | * | ||||
47 | * This property does not have any effect when fetching a specific event and | ||||
48 | * can be modified only when the job is not running. | ||||
49 | */ | ||||
50 | Q_PROPERTY(bool useDomainAdminAccess | ||||
51 | READ useDomainAdminAccess | ||||
52 | WRITE setUseDomainAdminAccess) | ||||
53 | | ||||
40 | public: | 54 | public: | ||
41 | explicit TeamdriveModifyJob(const TeamdrivePtr &teamdrive, | 55 | explicit DrivesModifyJob(const DrivesPtr &drives, | ||
42 | const AccountPtr &account, QObject *parent = nullptr); | 56 | const AccountPtr &account, QObject *parent = nullptr); | ||
43 | explicit TeamdriveModifyJob(const TeamdrivesList &teamdrives, | 57 | explicit DrivesModifyJob(const DrivesList &drives, | ||
44 | const AccountPtr &account, QObject *parent = nullptr); | 58 | const AccountPtr &account, QObject *parent = nullptr); | ||
45 | ~TeamdriveModifyJob() override; | 59 | ~DrivesModifyJob() override; | ||
60 | | ||||
61 | void setUseDomainAdminAccess(bool useDomainAdminAccess); | ||||
62 | bool useDomainAdminAccess() const; | ||||
46 | 63 | | |||
47 | protected: | 64 | protected: | ||
48 | void start() override; | 65 | void start() override; | ||
49 | KGAPI2::ObjectsList handleReplyWithItems(const QNetworkReply *reply, | 66 | KGAPI2::ObjectsList handleReplyWithItems(const QNetworkReply *reply, | ||
50 | const QByteArray &rawData) override; | 67 | const QByteArray &rawData) override; | ||
51 | 68 | | |||
52 | private: | 69 | private: | ||
53 | class Private; | 70 | class Private; | ||
54 | QScopedPointer<Private> d; | 71 | QScopedPointer<Private> d; | ||
55 | friend class Private; | 72 | friend class Private; | ||
56 | }; | 73 | }; | ||
57 | 74 | | |||
58 | } // namespace Drive | 75 | } // namespace Drive | ||
59 | 76 | | |||
60 | } // namespace KGAPI2 | 77 | } // namespace KGAPI2 | ||
61 | 78 | | |||
62 | #endif // KGAPI2_DRIVETEAMDRIVEMODIFYJOB_H | 79 | #endif // KGAPI2_DRIVEDRIVESMODIFYJOB_H |