libosmscout  1.1.1
POILookupModule.h
Go to the documentation of this file.
1 #ifndef OSMSCOUT_CLIENT_QT_POILOOKUPSERVICE_H
2 #define OSMSCOUT_CLIENT_QT_POILOOKUPSERVICE_H
3 /*
4  OSMScout - a Qt backend for libosmscout and libosmscout-map
5  Copyright (C) 2018 Lukas Karas
6 
7  This library is free software; you can redistribute it and/or
8  modify it under the terms of the GNU Lesser General Public
9  License as published by the Free Software Foundation; either
10  version 2.1 of the License, or (at your option) any later version.
11 
12  This library is distributed in the hope that it will be useful,
13  but WITHOUT ANY WARRANTY; without even the implied warranty of
14  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  Lesser General Public License for more details.
16 
17  You should have received a copy of the GNU Lesser General Public
18  License along with this library; if not, write to the Free Software
19  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20  */
21 
22 #include <osmscout/DBThread.h>
23 
25 
26 #include <QObject>
27 
28 namespace osmscout {
29 
34 {
35  Q_OBJECT
36 
37 signals:
38  void lookupAborted(int requestId);
39  void lookupFinished(int requestId);
40  void lookupResult(int requestId, QList<LocationEntry> locations);
41 
42 public slots:
43  void lookupPOIRequest(int requestId,
44  osmscout::BreakerRef breaker,
45  osmscout::GeoCoord searchCenter,
46  QStringList types,
47  double maxDistance);
48 
49 private:
50  QThread *thread;
51  DBThreadRef dbThread;
52 
53 public:
54  POILookupModule(QThread *thread,DBThreadRef dbThread);
55 
56  ~POILookupModule() override;
57 
58 private:
59  QList<LocationEntry> doPOIlookup(DBInstanceRef db,
60  osmscout::GeoBox searchBoundingBox,
61  osmscout::BreakerRef breaker,
62  QStringList types);
63 
64 };
65 
66 }
67 
68 #endif //OSMSCOUT_CLIENT_QT_POILOOKUPSERVICE_H
#define OSMSCOUT_CLIENT_QT_API
Definition: ClientQtImportExport.h:45
std::shared_ptr< Breaker > BreakerRef
Definition: Breaker.h:65
Definition: Area.h:38
std::shared_ptr< DBThread > DBThreadRef
Definition: DBThread.h:239
std::shared_ptr< DBInstance > DBInstanceRef
Definition: DBInstance.h:217
Definition: POILookupModule.h:33