1f87a8ac1fd91c3427501dd454f31d5bde1e17c8
[platform/core/api/maps-service.git] / src / plugin / empty_module.cpp
1 /* Copyright (c) 2010-2014 Samsung Electronics Co., Ltd. All rights reserved.
2  *
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 #include "discovery.h"
18 #include "empty_module.h"
19
20
21 /* Set of empty functions */
22
23 /* Plugin dedicated functions */
24 int maps_plugin_init_empty(maps_plugin_h *plugin)
25 {
26         return 0;
27 }
28
29 int maps_plugin_init_module_empty(maps_plugin_h *plugin, const char *module)
30 {
31         return 0;
32 }
33
34 int maps_plugin_shutdown_empty(maps_plugin_h plugin)
35 {
36         return 0;
37 }
38
39 int maps_plugin_get_info_empty(maps_plugin_info_h *info)
40 {
41         return 0;
42 }
43
44 int maps_plugin_request_user_consent_empty(const char *provider,
45                                                                 maps_service_request_user_consent_cb callback,
46                                                                 void *user_data)
47 {
48         return 0;
49 }
50
51 /* Maps Provider access key, preference and capabilities */
52 int maps_plugin_set_provider_key_empty(const char *provider_key)
53 {
54         return 0;
55 }
56
57 int maps_plugin_get_provider_key_empty(char **provider_key)
58 {
59         return 0;
60 }
61
62 int maps_plugin_set_preference_empty(maps_preference_h preference)
63 {
64         return 0;
65 }
66
67 int maps_plugin_get_preference_empty(maps_preference_h *preference)
68 {
69         return 0;
70 }
71
72 int maps_plugin_is_service_supported_empty(maps_service_e service, bool *supported)
73 {
74         return 0;
75 }
76
77 int maps_plugin_is_data_supported_empty(maps_service_data_e data, bool *supported)
78 {
79         return 0;
80 }
81
82 /* Geocode */
83 int maps_plugin_geocode_empty(const char *address,
84                                                                 const maps_preference_h preference,
85                                                                 const maps_service_geocode_cb callback,
86                                                                 void *user_data, int *request_id)
87 {
88         return 0;
89 }
90
91 int maps_plugin_geocode_inside_area_empty(const char *address,
92                                                                 const maps_area_h bounds,
93                                                                 const maps_preference_h preference,
94                                                                 maps_service_geocode_cb callback,
95                                                                 void *user_data, int *request_id)
96 {
97         return 0;
98 }
99
100 int maps_plugin_geocode_by_structured_address_empty(const maps_address_h address,
101                                                                 const maps_preference_h preference,
102                                                                 maps_service_geocode_cb callback,
103                                                                 void *user_data,
104                                                                 int *request_id)
105 {
106         return 0;
107 }
108
109 int maps_plugin_reverse_geocode_empty(double latitude, double longitude,
110                                                                 const maps_preference_h preference,
111                                                                 maps_service_reverse_geocode_cb
112                                                                 callback, void *user_data,
113                                                                 int *request_id)
114 {
115         return 0;
116 }
117
118 int maps_plugin_multi_reverse_geocode_empty(const maps_coordinates_list_h maps_list,
119                                                                 const maps_preference_h preference,
120                                                                 maps_service_multi_reverse_geocode_cb callback,
121                                                                 void *user_data, int *request_id)
122 {
123         return 0;
124 }
125
126 /* Place */
127 int maps_plugin_search_place_empty(const maps_coordinates_h position,
128                                                                 int distance,
129                                                                 const maps_place_filter_h filter,
130                                                                 maps_preference_h preference,
131                                                                 maps_service_search_place_cb callback,
132                                                                 void *user_data, int *request_id)
133 {
134         return 0;
135 }
136
137 int maps_plugin_search_place_by_area_empty(const maps_area_h boundary,
138                                                                 const maps_place_filter_h filter,
139                                                                 maps_preference_h preference,
140                                                                 maps_service_search_place_cb callback,
141                                                                 void *user_data,
142                                                                 int *request_id)
143 {
144         return 0;
145 }
146
147 int maps_plugin_search_place_by_address_empty(const char *address,
148                                                                 const maps_area_h boundary,
149                                                                 const maps_place_filter_h filter,
150                                                                 maps_preference_h preference,
151                                                                 maps_service_search_place_cb callback,
152                                                                 void *user_data,
153                                                                 int *request_id)
154 {
155         return 0;
156 }
157
158 int maps_plugin_search_place_list_empty(const maps_area_h boundary,
159                                                                 const maps_place_filter_h filter,
160                                                                 maps_preference_h preference,
161                                                                 maps_service_search_place_list_cb callback,
162                                                                 void *user_data, int *request_id)
163 {
164         return 0;
165 }
166
167 int maps_plugin_get_place_details_empty(const char *url,
168                                                                 maps_service_get_place_details_cb callback,
169                                                                 void *user_data, int *request_id)
170 {
171         return 0;
172 }
173
174 /* Route */
175 int maps_plugin_search_route_empty(const maps_coordinates_h origin,
176                                                                 const maps_coordinates_h destination,
177                                                                 maps_preference_h preference,
178                                                                 maps_service_search_route_cb callback,
179                                                                 void *user_data, int *request_id)
180 {
181         return 0;
182 }
183
184 int maps_plugin_search_route_waypoints_empty(const maps_coordinates_h *waypoint_list,
185                                                                 int waypoint_num,
186                                                                 maps_preference_h preference,
187                                                                 maps_service_search_route_cb callback,
188                                                                 void *user_data, int *request_id)
189 {
190         return 0;
191 }
192
193 /* Cancel Request */
194 int maps_plugin_cancel_request_empty(int request_id)
195 {
196         return 0;
197 }
198
199 /* Mapping */
200 int maps_plugin_create_map_view_empty(maps_view_h view, maps_plugin_map_view_ready_cb callback)
201 {
202         return 0;
203 }
204
205 int maps_plugin_destroy_map_view_empty(maps_view_h view)
206 {
207         return 0;
208 }
209
210 int maps_plugin_render_map_empty(maps_view_h view,
211                                                                 const maps_coordinates_h coordinates,
212                                                                 double zoom_factor,
213                                                                 double rotation_angle)
214 {
215         return 0;
216 }
217
218 int maps_plugin_move_center_empty(maps_view_h view, const int delta_x, const int delta_y)
219 {
220         return 0;
221 }
222
223 int maps_plugin_set_scalebar_empty(maps_view_h view, bool enable)
224 {
225         return 0;
226 }
227
228 int maps_plugin_get_scalebar_empty(maps_view_h view, bool *enabled)
229 {
230         return 0;
231 }
232
233 int maps_plugin_on_object_empty(maps_view_h view,
234                                                                 const maps_view_object_h object,
235                                                                 maps_view_object_operation_e operation)
236 {
237         return 0;
238 }
239
240 int maps_plugin_screen_to_geography_empty(maps_view_h view, const int x, const int y,
241                                                                 maps_coordinates_h *coordinates)
242 {
243         return 0;
244 }
245
246 int maps_plugin_geography_to_screen_empty(maps_view_h view,
247                                                                 const maps_coordinates_h coordinates, int* x, int* y)
248 {
249         return 0;
250 }
251
252 int maps_plugin_get_min_zoom_level_empty(maps_view_h view, int *min_zoom_level)
253 {
254         return 0;
255 }
256
257 int maps_plugin_get_max_zoom_level_empty(maps_view_h view, int *max_zoom_level)
258 {
259         return 0;
260 }
261
262 int maps_plugin_get_center_empty(maps_view_h view, maps_coordinates_h *coordinates)
263 {
264         return 0;
265 }
266
267 int maps_plugin_capture_snapshot_empty(maps_view_h view, void **data, int *width, int *height,
268                                                                 maps_view_colorspace_type_e *cs)
269 {
270         return 0;
271 }
272
273 int maps_plugin_get_view_scale_factor_empty(maps_view_h view, double *scale_factor)
274 {
275         return 0;
276 }
277
278 int maps_plugin_set_view_scale_factor_empty(maps_view_h view, double scale_factor)
279 {
280         return 0;
281 }
282
283
284 /* Interface of a plugin with all empty functions */
285 plugin::interface_s empty_interface = {
286         /* Plugin dedicated functions */
287         maps_plugin_init_empty,
288         maps_plugin_shutdown_empty,
289         maps_plugin_get_info_empty,
290         maps_plugin_init_module_empty,
291         maps_plugin_request_user_consent_empty,
292
293         maps_plugin_set_provider_key_empty,
294         maps_plugin_get_provider_key_empty,
295         maps_plugin_set_preference_empty,
296         maps_plugin_get_preference_empty,
297         maps_plugin_is_service_supported_empty,
298         maps_plugin_is_data_supported_empty,
299
300         /* Geocode */
301         maps_plugin_geocode_empty,
302         maps_plugin_geocode_inside_area_empty,
303         maps_plugin_geocode_by_structured_address_empty,
304         maps_plugin_reverse_geocode_empty,
305         maps_plugin_multi_reverse_geocode_empty,
306
307         /* Place */
308         maps_plugin_search_place_empty,
309         maps_plugin_search_place_by_area_empty,
310         maps_plugin_search_place_by_address_empty,
311         maps_plugin_search_place_list_empty,
312         maps_plugin_get_place_details_empty,
313
314         /* Route */
315         maps_plugin_search_route_empty,
316         maps_plugin_search_route_waypoints_empty,
317
318         /* Cancel Request */
319         maps_plugin_cancel_request_empty,
320
321         /* Mapping */
322         maps_plugin_create_map_view_empty,
323         maps_plugin_destroy_map_view_empty,
324         maps_plugin_render_map_empty,
325         maps_plugin_move_center_empty,
326         maps_plugin_set_scalebar_empty,
327         maps_plugin_get_scalebar_empty,
328         maps_plugin_on_object_empty,
329         maps_plugin_screen_to_geography_empty,
330         maps_plugin_geography_to_screen_empty,
331         maps_plugin_get_min_zoom_level_empty,
332         maps_plugin_get_max_zoom_level_empty,
333         maps_plugin_get_center_empty,
334         maps_plugin_capture_snapshot_empty,
335         maps_plugin_get_view_scale_factor_empty,
336         maps_plugin_set_view_scale_factor_empty,
337 };
338
339
340 plugin::interface_s &plugin::get_empty_interface()
341 {
342         return empty_interface;
343 }
344
345 plugin::interface_s *plugin::get_empty_interface_ptr()
346 {
347         return &empty_interface;
348 }