Kgapi

drivessearchquery.h
1/*
2 * SPDX-FileCopyrightText: 2019 David Barchiesi <david@barchie.si>
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 "kgapidrive_export.h"
10
11#include "searchquery.h"
12
13#include <QSharedDataPointer>
14#include <QVariant>
15
16namespace KGAPI2
17{
18namespace Drive
19{
20
21/**
22 * DrivesSearchQuery class allows simply building even complex shared drive search queries
23 * for DrivesFetchJob.
24 *
25 * See https://developers.google.com/drive/api/v2/search-shareddrives for allowed
26 * combinations of fields, compare operators, and value types.
27 */
28class KGAPIDRIVE_EXPORT DrivesSearchQuery : public SearchQuery
29{
30public:
31 enum Field { Name, Hidden, CreatedDate, MemberCount, OrganizerCount };
32
33 using SearchQuery::SearchQuery;
34
35 using SearchQuery::addQuery;
36 void addQuery(Field field, CompareOperator op, const QVariant &value);
37
38private:
39 QString fieldToString(Field field);
40 QString valueToString(DrivesSearchQuery::Field field, const QVariant &var);
41};
42}
43}
DrivesSearchQuery class allows simply building even complex shared drive search queries for DrivesFet...
SearchQuery class should be used as a base class for building file/team search queries.
Definition searchquery.h:24
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 Fri Nov 22 2024 12:08:13 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.