1// qgeoserviceprovider.sip generated by MetaSIP 2// 3// This file is part of the QtLocation Python extension module. 4// 5// Copyright (c) 2021 Riverbank Computing Limited <info@riverbankcomputing.com> 6// 7// This file is part of PyQt5. 8// 9// This file may be used under the terms of the GNU General Public License 10// version 3.0 as published by the Free Software Foundation and appearing in 11// the file LICENSE included in the packaging of this file. Please review the 12// following information to ensure the GNU General Public License version 3.0 13// requirements will be met: http://www.gnu.org/copyleft/gpl.html. 14// 15// If you do not wish to use this file under the terms of the GPL version 3.0 16// then you may purchase a commercial license. For more information contact 17// info@riverbankcomputing.com. 18// 19// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 20// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 21 22 23%If (Qt_5_11_0 -) 24class QNavigationManager; 25%End 26%If (Qt_5_5_0 -) 27 28class QGeoServiceProvider : QObject 29{ 30%TypeHeaderCode 31#include <qgeoserviceprovider.h> 32%End 33 34%ConvertToSubClassCode 35 static struct class_graph { 36 const char *name; 37 sipTypeDef **type; 38 int yes, no; 39 } graph[] = { 40 {sipName_QGeoCodingManager, &sipType_QGeoCodingManager, -1, 1}, 41 {sipName_QGeoRoutingManagerEngine, &sipType_QGeoRoutingManagerEngine, -1, 2}, 42 {sipName_QGeoCodeReply, &sipType_QGeoCodeReply, -1, 3}, 43 {sipName_QPlaceReply, &sipType_QPlaceReply, 10, 4}, 44 {sipName_QPlaceManagerEngine, &sipType_QPlaceManagerEngine, -1, 5}, 45 {sipName_QGeoRoutingManager, &sipType_QGeoRoutingManager, -1, 6}, 46 {sipName_QGeoCodingManagerEngine, &sipType_QGeoCodingManagerEngine, -1, 7}, 47 {sipName_QGeoServiceProvider, &sipType_QGeoServiceProvider, -1, 8}, 48 {sipName_QGeoRouteReply, &sipType_QGeoRouteReply, -1, 9}, 49 {sipName_QPlaceManager, &sipType_QPlaceManager, -1, -1}, 50 {sipName_QPlaceSearchSuggestionReply, &sipType_QPlaceSearchSuggestionReply, -1, 11}, 51 {sipName_QPlaceMatchReply, &sipType_QPlaceMatchReply, -1, 12}, 52 {sipName_QPlaceDetailsReply, &sipType_QPlaceDetailsReply, -1, 13}, 53 {sipName_QPlaceContentReply, &sipType_QPlaceContentReply, -1, 14}, 54 {sipName_QPlaceSearchReply, &sipType_QPlaceSearchReply, -1, 15}, 55 {sipName_QPlaceIdReply, &sipType_QPlaceIdReply, -1, -1}, 56 }; 57 58 int i = 0; 59 60 sipType = NULL; 61 62 do 63 { 64 struct class_graph *cg = &graph[i]; 65 66 if (cg->name != NULL && sipCpp->inherits(cg->name)) 67 { 68 sipType = *cg->type; 69 i = cg->yes; 70 } 71 else 72 i = cg->no; 73 } 74 while (i >= 0); 75%End 76 77public: 78 enum Error 79 { 80 NoError, 81 NotSupportedError, 82 UnknownParameterError, 83 MissingRequiredParameterError, 84 ConnectionError, 85%If (Qt_5_12_1 -) 86 LoaderError, 87%End 88 }; 89 90 enum RoutingFeature 91 { 92 NoRoutingFeatures, 93 OnlineRoutingFeature, 94 OfflineRoutingFeature, 95 LocalizedRoutingFeature, 96 RouteUpdatesFeature, 97 AlternativeRoutesFeature, 98 ExcludeAreasRoutingFeature, 99 AnyRoutingFeatures, 100 }; 101 102 enum GeocodingFeature 103 { 104 NoGeocodingFeatures, 105 OnlineGeocodingFeature, 106 OfflineGeocodingFeature, 107 ReverseGeocodingFeature, 108 LocalizedGeocodingFeature, 109 AnyGeocodingFeatures, 110 }; 111 112 enum MappingFeature 113 { 114 NoMappingFeatures, 115 OnlineMappingFeature, 116 OfflineMappingFeature, 117 LocalizedMappingFeature, 118 AnyMappingFeatures, 119 }; 120 121 enum PlacesFeature 122 { 123 NoPlacesFeatures, 124 OnlinePlacesFeature, 125 OfflinePlacesFeature, 126 SavePlaceFeature, 127 RemovePlaceFeature, 128 SaveCategoryFeature, 129 RemoveCategoryFeature, 130 PlaceRecommendationsFeature, 131 SearchSuggestionsFeature, 132 LocalizedPlacesFeature, 133 NotificationsFeature, 134 PlaceMatchingFeature, 135 AnyPlacesFeatures, 136 }; 137 138 typedef QFlags<QGeoServiceProvider::RoutingFeature> RoutingFeatures; 139 typedef QFlags<QGeoServiceProvider::GeocodingFeature> GeocodingFeatures; 140 typedef QFlags<QGeoServiceProvider::MappingFeature> MappingFeatures; 141 typedef QFlags<QGeoServiceProvider::PlacesFeature> PlacesFeatures; 142 static QStringList availableServiceProviders(); 143 QGeoServiceProvider(const QString &providerName, const QVariantMap ¶meters = QVariantMap(), bool allowExperimental = false); 144 virtual ~QGeoServiceProvider(); 145 QGeoServiceProvider::RoutingFeatures routingFeatures() const; 146 QGeoServiceProvider::GeocodingFeatures geocodingFeatures() const; 147 QGeoServiceProvider::MappingFeatures mappingFeatures() const; 148 QGeoServiceProvider::PlacesFeatures placesFeatures() const; 149 QGeoCodingManager *geocodingManager() const; 150 QGeoRoutingManager *routingManager() const; 151 QPlaceManager *placeManager() const; 152 QGeoServiceProvider::Error error() const; 153 QString errorString() const; 154 void setParameters(const QVariantMap ¶meters); 155 void setLocale(const QLocale &locale); 156 void setAllowExperimental(bool allow); 157%If (Qt_5_11_0 -) 158 159 enum NavigationFeature 160 { 161 NoNavigationFeatures, 162 OnlineNavigationFeature, 163 OfflineNavigationFeature, 164 AnyNavigationFeatures, 165 }; 166 167%End 168%If (Qt_5_11_0 -) 169 typedef QFlags<QGeoServiceProvider::NavigationFeature> NavigationFeatures; 170%End 171%If (Qt_5_11_0 -) 172 QGeoServiceProvider::NavigationFeatures navigationFeatures() const; 173%End 174%If (Qt_5_11_0 -) 175 QNavigationManager *navigationManager() const; 176%End 177%If (Qt_5_13_0 -) 178 QGeoServiceProvider::Error mappingError() const; 179%End 180%If (Qt_5_13_0 -) 181 QString mappingErrorString() const; 182%End 183%If (Qt_5_13_0 -) 184 QGeoServiceProvider::Error geocodingError() const; 185%End 186%If (Qt_5_13_0 -) 187 QString geocodingErrorString() const; 188%End 189%If (Qt_5_13_0 -) 190 QGeoServiceProvider::Error routingError() const; 191%End 192%If (Qt_5_13_0 -) 193 QString routingErrorString() const; 194%End 195%If (Qt_5_13_0 -) 196 QGeoServiceProvider::Error placesError() const; 197%End 198%If (Qt_5_13_0 -) 199 QString placesErrorString() const; 200%End 201%If (Qt_5_13_0 -) 202 QGeoServiceProvider::Error navigationError() const; 203%End 204%If (Qt_5_13_0 -) 205 QString navigationErrorString() const; 206%End 207}; 208 209%End 210%If (Qt_5_5_0 -) 211QFlags<QGeoServiceProvider::RoutingFeature> operator|(QGeoServiceProvider::RoutingFeature f1, QFlags<QGeoServiceProvider::RoutingFeature> f2); 212%End 213%If (Qt_5_5_0 -) 214QFlags<QGeoServiceProvider::GeocodingFeature> operator|(QGeoServiceProvider::GeocodingFeature f1, QFlags<QGeoServiceProvider::GeocodingFeature> f2); 215%End 216%If (Qt_5_5_0 -) 217QFlags<QGeoServiceProvider::MappingFeature> operator|(QGeoServiceProvider::MappingFeature f1, QFlags<QGeoServiceProvider::MappingFeature> f2); 218%End 219%If (Qt_5_5_0 -) 220QFlags<QGeoServiceProvider::PlacesFeature> operator|(QGeoServiceProvider::PlacesFeature f1, QFlags<QGeoServiceProvider::PlacesFeature> f2); 221%End 222%If (Qt_5_11_0 -) 223QFlags<QGeoServiceProvider::NavigationFeature> operator|(QGeoServiceProvider::NavigationFeature f1, QFlags<QGeoServiceProvider::NavigationFeature> f2); 224%End 225