Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qgeocodingmanagerenginemapbox.h
Go to the documentation of this file.
1// Copyright (C) 2017 Mapbox, Inc.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QGEOCODINGMANAGERENGINEMAPBOX_H
5#define QGEOCODINGMANAGERENGINEMAPBOX_H
6
7#include <QtCore/QUrlQuery>
8#include <QtLocation/QGeoServiceProvider>
9#include <QtLocation/QGeoCodingManagerEngine>
10#include <QtLocation/QGeoCodeReply>
11
12QT_BEGIN_NAMESPACE
13
14class QNetworkAccessManager;
15
17{
19
20public:
24
25 QGeoCodeReply *geocode(const QGeoAddress &address, const QGeoShape &bounds) override;
26 QGeoCodeReply *geocode(const QString &address, int limit, int offset,
27 const QGeoShape &bounds) override;
28 QGeoCodeReply *reverseGeocode(const QGeoCoordinate &coordinate,
29 const QGeoShape &bounds) override;
30
31private slots:
32 void onReplyFinished();
33 void onReplyError(QGeoCodeReply::Error errorCode, const QString &errorString);
34
35private:
36 QGeoCodeReply *doSearch(const QString &, QUrlQuery &, const QGeoShape &bounds);
37
38 QNetworkAccessManager *m_networkManager;
39 QByteArray m_userAgent;
40 QString m_accessToken;
41 QString m_urlPrefix;
42 bool m_isEnterprise;
43};
44
45QT_END_NAMESPACE
46
47#endif // QGEOCODINGMANAGERENGINEMAPBOX_H
QGeoCodeReply * reverseGeocode(const QGeoCoordinate &coordinate, const QGeoShape &bounds) override
Begins the reverse geocoding of coordinate.
QGeoCodeReply * geocode(const QGeoAddress &address, const QGeoShape &bounds) override
Begins the geocoding of address.
QGeoCodeReply * geocode(const QString &address, int limit, int offset, const QGeoShape &bounds) override
Begins geocoding for a location matching address.