Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
geoserviceproviderfactory_esri.cpp
Go to the documentation of this file.
1// Copyright (C) 2013-2018 Esri <contracts@esri.com>
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
9
10#include <QtLocation/private/qgeotiledmappingmanagerengine_p.h>
11
13
15 const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const
16{
17 return new GeoCodingManagerEngineEsri(parameters, error, errorString);
18}
19
25
27 const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const
28{
29 const QString token = parameters.value(QStringLiteral("esri.token")).toString();
30
31 if (!token.isEmpty()) {
32 return new GeoRoutingManagerEngineEsri(parameters, error, errorString);
33 } else {
35 *errorString = tr("Esri plugin requires a 'esri.token' parameter.\n"
36 "Please visit https://developers.arcgis.com/authentication/accessing-arcgis-online-services/");
37 return nullptr;
38 }
39}
40
42 const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const
43{
44 return new PlaceManagerEngineEsri(parameters, error, errorString);
45}
46
Q_PLUGIN_METADATA(IID "org.qt-project.qt.geoservice.serviceproviderfactory/6.0" FILE "esri_plugin.json") public QGeoMappingManagerEngine * createMappingManagerEngine(const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const override
Returns a new QGeoMappingManagerEngine instance, initialized with parameters, which implements mappin...
QPlaceManagerEngine * createPlaceManagerEngine(const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const override
Returns a new QPlaceManagerEngine instance, initialized with parameters, which implements the place s...
QGeoRoutingManagerEngine * createRoutingManagerEngine(const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const override
Returns a new QGeoRoutingManagerEngine instance, initialized with parameters, which implements routin...
virtual QGeoCodingManagerEngine * createGeocodingManagerEngine(const QVariantMap &parameters, QGeoServiceProvider::Error *error, QString *errorString) const
Returns a new QGeoCodingManagerEngine instance, initialized with parameters, which implements the loc...
Error
Describes an error related to the loading and setup of a service provider plugin.
T value(const Key &key, const T &defaultValue=T()) const
Definition qmap.h:357
\inmodule QtLocation
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
QString toString() const
Returns the variant as a QString if the variant has a userType() including, but not limited to:
Token token
Definition keywords.cpp:444
Combined button and popup list for selecting options.
DBusConnection const char DBusError * error
#define QStringLiteral(str)
#define tr(X)