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
qgeoserviceproviderfactory.cpp
Go to the documentation of this file.
1// Copyright (C) 2022 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3// Qt-Security score:significant reason:default
4
6
7QT_BEGIN_NAMESPACE
8
9/*!
10 \class QGeoServiceProviderFactory
11 \inmodule QtLocation
12 \ingroup QtLocation-impl
13 \since 5.6
14 \deprecated
15
16 \brief The QGeoServiceProviderFactory class is a factory class used as the
17 plugin interface for services related to geographical information.
18
19 \note There are no source or binary compatibility guarantees for the
20 backend classes. The API is only guaranteed to work with the Qt version it
21 was developed against. API changes will however only be made in minor
22 releases. (6.6, 6.7, and so on.)
23
24 Implementers must provide a unique combination of providerName() and
25 providerVersion() per plugin.
26
27 The other functions should be overridden if the plugin supports the
28 associated set of functionality.
29*/
30
31/*!
32 \fn QGeoServiceProviderFactory::~QGeoServiceProviderFactory()
33
34 Destroys this QGeoServiceProviderFactory instance.
35*/
36
37/*!
38 Returns a new QGeoCodingManagerEngine instance, initialized with \a
39 parameters, which implements the location geocoding functionality.
40
41 If \a error is not \nullptr it should be set to QGeoServiceProvider::NoError on
42 success or an appropriate QGeoServiceProvider::Error on failure.
43
44 If \a errorString is not \nullptr it should be set to a string describing any
45 error which occurred.
46
47 The default implementation returns \nullptr, which causes a
48 QGeoServiceProvider::NotSupportedError in QGeoServiceProvider.
49*/
50QGeoCodingManagerEngine *
51QGeoServiceProviderFactory::createGeocodingManagerEngine(const QVariantMap &parameters,
52 QGeoServiceProvider::Error *error,
53 QString *errorString) const
54{
55 Q_UNUSED(parameters);
56 Q_UNUSED(error);
57 Q_UNUSED(errorString);
58
59 return nullptr;
60}
61
62/*!
63 Returns a new QGeoMappingManagerEngine instance, initialized with \a
64 parameters, which implements mapping functionality.
65
66 If \a error is not \nullptr it should be set to QGeoServiceProvider::NoError on
67 success or an appropriate QGeoServiceProvider::Error on failure.
68
69 If \a errorString is not \nullptr it should be set to a string describing any
70 error which occurred.
71
72 The default implementation returns \nullptr, which causes a
73 QGeoServiceProvider::NotSupportedError in QGeoServiceProvider.
74
75 \internal
76*/
77QGeoMappingManagerEngine *
78QGeoServiceProviderFactory::createMappingManagerEngine(const QVariantMap &parameters,
79 QGeoServiceProvider::Error *error,
80 QString *errorString) const
81{
82 Q_UNUSED(parameters);
83 Q_UNUSED(error);
84 Q_UNUSED(errorString);
85
86 return nullptr;
87}
88
89/*!
90 Returns a new QGeoRoutingManagerEngine instance, initialized with \a
91 parameters, which implements routing functionality.
92
93 If \a error is not \nullptr it should be set to QGeoServiceProvider::NoError on
94 success or an appropriate QGeoServiceProvider::Error on failure.
95
96 If \a errorString is not \nullptr it should be set to a string describing any
97 error which occurred.
98
99 The default implementation returns \nullptr, which causes a
100 QGeoServiceProvider::NotSupportedError in QGeoServiceProvider.
101*/
102QGeoRoutingManagerEngine *
103QGeoServiceProviderFactory::createRoutingManagerEngine(const QVariantMap &parameters,
104 QGeoServiceProvider::Error *error,
105 QString *errorString) const
106
107{
108 Q_UNUSED(parameters);
109 Q_UNUSED(error);
110 Q_UNUSED(errorString);
111
112 return nullptr;
113}
114
115/*!
116 Returns a new QPlaceManagerEngine instance, initialized with \a
117 parameters, which implements the place searching functionality.
118
119 If \a error is not \nullptr it should be set to QGeoServiceProvider::NoError on
120 success or an appropriate QGeoServiceProvider::Error on failure.
121
122 If \a errorString is not \nullptr it should be set to a string describing any
123 error which occurred.
124
125 The default implementation returns \nullptr, which causes a
126 QGeoServiceProvider::NotSupportedError in QGeoServiceProvider.
127*/
128QPlaceManagerEngine *
129QGeoServiceProviderFactory::createPlaceManagerEngine(const QVariantMap &parameters,
130 QGeoServiceProvider::Error *error,
131 QString *errorString) const
132{
133 Q_UNUSED(parameters);
134 Q_UNUSED(error);
135 Q_UNUSED(errorString);
136
137 return nullptr;
138}
139
140/*!
141 Notify the plugin when the qml \a engine is ready. In this moment the plugins can use it
142 to register Image Providers.
143
144 The default implementation does nothing.
145 \since 5.12
146*/
147void QGeoServiceProviderFactory::setQmlEngine(QQmlEngine *engine)
148{
149 Q_UNUSED(engine);
150}
151
152QT_END_NAMESPACE