tizen 2.4 release
[framework/location/maps-plugin-here.git] / src / here / here_revgeocode.h
1 /*
2  * Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 #ifndef _LOCATION_HERE_REV_GEOCODER_H_
18 #define _LOCATION_HERE_REV_GEOCODER_H_
19
20 //plug-in header
21 #include "here_manager.h"
22
23 #include <maps_coordinates.h>
24
25 //map engine header
26 #include <geocoder/ReverseGeoCoderQuery.h>
27 #include <geocoder/GeoCoderQueryListener.h>
28 #include <geocoder/GeoCoderReply.h>
29 #include <geocoder/Result.h>
30 #include <common/GeoLocation.h>
31 #include <common/Address.h>
32
33 HERE_PLUGIN_BEGIN_NAMESPACE
34
35 using namespace HERE_MAPS_NAMESPACE_PREFIX;
36
37 class HereRevGeocode
38 : public HereBase
39 , public GeoCoderQueryListener
40 {
41 public:
42         /**
43          *This is the default constructor for reverse Geocoder.
44          */
45
46         HereRevGeocode(void *pCbFunc, void *pUserData, int nReqId);
47
48         /**
49          *This is the default destructor for reverse Geocoder.
50          */
51
52         ~HereRevGeocode();
53
54
55         here_error_e PrepareQuery();
56         here_error_e PreparePreference(maps_preference_h hPref);
57         here_error_e PreparePosition(double dLat, double dLng);
58
59         here_error_e StartRevGeocode(maps_item_hashtable_h hPref);
60
61         virtual void OnGeoCoderReply(const GeoCoderReply& Reply);
62
63 private:
64         ReverseGeoCoderQuery* m_pQuery;
65         GeoCoordinates m_geoCoord;
66 };
67
68 HERE_PLUGIN_END_NAMESPACE
69
70 #endif //_LOCATION_HERE_REV_GEOCODER_H_