QGIS API Documentation  3.20.0-Odense (decaadbb31)
qgsarcgisportalutils.h
Go to the documentation of this file.
1 /***************************************************************************
2  qgsarcgisportalutils.h
3  --------------------
4  begin : December 2020
5  copyright : (C) 2020 by Nyall Dawson
6  email : nyall dot dawson at gmail dot com
7  ***************************************************************************
8  * *
9  * This program is free software; you can redistribute it and/or modify *
10  * it under the terms of the GNU General Public License as published by *
11  * the Free Software Foundation; either version 2 of the License, or *
12  * (at your option) any later version. *
13  * *
14  ***************************************************************************/
15 #ifndef QGSARCGISPORTALUTILS_H
16 #define QGSARCGISPORTALUTILS_H
17 
18 #include "qgis_core.h"
19 #include "qgis_sip.h"
20 
21 #include <QVariantMap>
22 #include <QString>
23 
24 class QgsFeedback;
25 
35 class CORE_EXPORT QgsArcGisPortalUtils
36 {
37  public:
38 
42  enum ItemType
43  {
47  };
48 
64  static QVariantMap retrieveUserInfo( const QString &communityUrl, const QString &user, const QString &authcfg, QString &errorTitle SIP_OUT, QString &errorText SIP_OUT, const QMap< QString, QString > &requestHeaders = QMap< QString, QString >(), QgsFeedback *feedback = nullptr );
65 
81  static QVariantList retrieveUserGroups( const QString &communityUrl, const QString &user, const QString &authcfg, QString &errorTitle SIP_OUT, QString &errorText SIP_OUT, const QMap< QString, QString > &requestHeaders = QMap< QString, QString >(), QgsFeedback *feedback = nullptr );
82 
97  static QVariantList retrieveGroupContent( const QString &contentUrl, const QString &groupId, const QString &authcfg, QString &errorTitle SIP_OUT, QString &errorText SIP_OUT, const QMap< QString, QString > &requestHeaders = QMap< QString, QString >(), QgsFeedback *feedback = nullptr, int pageSize = 100 );
98 
114  static QVariantList retrieveGroupItemsOfType( const QString &contentUrl, const QString &groupId, const QString &authcfg,
115  const QList< int > &itemTypes,
116  QString &errorTitle SIP_OUT, QString &errorText SIP_OUT, const QMap< QString, QString > &requestHeaders = QMap< QString, QString >(), QgsFeedback *feedback = nullptr, int pageSize = 100 );
117 
118 
119  private:
120 
121  static QString typeToString( ItemType type );
122 
123 };
124 
125 #endif // QGSARCGISPORTALUTILS_H
Utility functions for working with ArcGIS REST services.
ItemType
Portal item types (not complete)
@ MapService
ArcGIS Server map service.
@ FeatureService
ArcGIS Server feature service.
@ ImageService
ArcGIS Server image service.
Base class for feedback objects to be used for cancellation of something running in a worker thread.
Definition: qgsfeedback.h:45
#define SIP_OUT
Definition: qgis_sip.h:58