2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
17 #ifndef __TIZEN_NETWORK_TETHERING_H__
18 #define __TIZEN_NETWORK_TETHERING_H__
32 * @addtogroup CAPI_NETWORK_TETHERING_MANAGER_MODULE
37 * @brief The tethering handle.
40 typedef void * tethering_h;
43 * @brief Enumeration for the tethering.
47 TETHERING_ERROR_NONE = TIZEN_ERROR_NONE, /**< Successful */
48 TETHERING_ERROR_NOT_PERMITTED = TIZEN_ERROR_NOT_PERMITTED, /**< Operation not permitted */
49 TETHERING_ERROR_INVALID_PARAMETER = TIZEN_ERROR_INVALID_PARAMETER, /**< Invalid parameter */
50 TETHERING_ERROR_OUT_OF_MEMORY = TIZEN_ERROR_OUT_OF_MEMORY, /**< Out of memory */
51 TETHERING_ERROR_RESOURCE_BUSY = TIZEN_ERROR_RESOURCE_BUSY, /**< Resource busy */
52 TETHERING_ERROR_NOT_ENABLED = TIZEN_ERROR_TETHERING | 0x0501, /**< Not enabled */
53 TETHERING_ERROR_OPERATION_FAILED = TIZEN_ERROR_TETHERING | 0x0502, /**< Operation failed */
54 TETHERING_ERROR_INVALID_OPERATION = TIZEN_ERROR_INVALID_OPERATION, /**< Invalid operation */
55 TETHERING_ERROR_NOT_SUPPORT_API = TIZEN_ERROR_NOT_SUPPORTED, /**< API is not supported */
56 TETHERING_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED, /**< Permission denied */
60 * @brief Enumeration for the type of tethering.
64 TETHERING_TYPE_ALL = 0, /**< All type */
65 TETHERING_TYPE_USB, /**< USB type */
66 TETHERING_TYPE_WIFI, /**< Wi-Fi type */
67 TETHERING_TYPE_BT, /**< BT type */
71 * @brief Enumeration for the cause of disabling the tethering.
76 TETHERING_DISABLED_BY_USB_DISCONNECTION = 0, /**< Disabled due to usb disconnection */
77 TETHERING_DISABLED_BY_FLIGHT_MODE, /**< Disabled due to flight mode */
78 TETHERING_DISABLED_BY_LOW_BATTERY, /**< Disabled due to low battery */
79 TETHERING_DISABLED_BY_NETWORK_CLOSE, /**< Disabled due to pdp network close */
80 TETHERING_DISABLED_BY_TIMEOUT, /**< Disabled due to timeout */
81 TETHERING_DISABLED_BY_OTHERS, /**< Disabled by other apps */
82 TETHERING_DISABLED_BY_REQUEST, /**< Disabled by your request */
83 TETHERING_DISABLED_BY_WIFI_ON, /**< Disabled due to Wi-Fi on */
84 TETHERING_DISABLED_BY_BT_OFF, /**< Disabled due to Bluetooth off */
85 } tethering_disabled_cause_e;
93 * @addtogroup CAPI_NETWORK_TETHERING_WIFI_MODULE
98 * @brief Enumeration for the Wi-Fi security.
102 TETHERING_WIFI_SECURITY_TYPE_NONE = 0, /**< No Security type */
103 TETHERING_WIFI_SECURITY_TYPE_WPA2_PSK, /**< WPA2_PSK */
104 } tethering_wifi_security_type_e;
107 * @brief Enumeration for the Wi-Fi mode
111 TETHERING_WIFI_MODE_TYPE_B = 0, /**< mode b */
112 TETHERING_WIFI_MODE_TYPE_G, /**< mode g */
113 TETHERING_WIFI_MODE_TYPE_A, /**< mode a */
114 TETHERING_WIFI_MODE_TYPE_AD, /**< mode ad */
115 } tethering_wifi_mode_type_e;
123 * @addtogroup CAPI_NETWORK_TETHERING_CLIENT_MODULE
128 * @brief The tethering client handle.
131 typedef void * tethering_client_h;
134 * @brief Enumeration for address family.
138 TETHERING_ADDRESS_FAMILY_IPV4 = 0, /**< IPV4 Address type */
139 } tethering_address_family_e;
147 * @addtogroup CAPI_NETWORK_TETHERING_MANAGER_MODULE
152 * @brief Called when the tethering is enabled.
154 * @param[in] result The result of enabling the tethering
155 * @param[in] type The tethering type
156 * @param[in] is_requested Indicates whether this change is requested
157 * @param[in] user_data The user data passed from tethering_set_enabled_cb()
158 * @pre If you register callback function using tethering_set_enabled_cb(), this will be invoked when the tethering is enabled.
159 * @see tethering_enable()
160 * @see tethering_unset_enabled_cb()
162 typedef void (*tethering_enabled_cb)(tethering_error_e result, tethering_type_e type, bool is_requested, void *user_data);
165 * @brief Called when the tethering is disabled.
167 * @param[in] result The result of disabling the tethering
168 * @param[in] type The tethering type
169 * @param[in] cause The cause of disabling
170 * @param[in] user_data The user data passed from tethering_set_disabled_cb()
171 * @pre If you register callback function using tethering_set_disabled_cb(), this will be invoked when the tethering is disabled.
172 * @see tethering_set_disabled_cb()
173 * @see tethering_unset_disabled_cb()
175 typedef void (*tethering_disabled_cb)(tethering_error_e result, tethering_type_e type, tethering_disabled_cause_e cause, void *user_data);
178 * @brief Called when the connection state is changed.
180 * @remarks @a client is valid only in this function. In order to use it outside this function, a user must copy the client with tethering_client_clone().
181 * @param[in] client The client of which connection state is changed
182 * @param[in] opened @c true when connection is opened, otherwise false
183 * @param[in] user_data The user data passed from tethering_set_connection_state_changed_cb()
184 * @pre If you register callback function using tethering_set_connection_state_changed_cb(), this will be invoked when the connection state is changed.
185 * @see tethering_set_connection_state_changed_cb()
186 * @see tethering_unset_connection_state_changed_cb()
188 typedef void (*tethering_connection_state_changed_cb)(tethering_client_h client, bool opened, void *user_data);
191 * @brief Called when you get the connected client repeatedly.
193 * @remarks @a client is valid only in this function. In order to use the client outside this function, a user must copy the client with tethering_client_clone().
194 * @param[in] client The connected client
195 * @param[in] user_data The user data passed from the request function
196 * @return @c true to continue with the next iteration of the loop, \n @c false to break out of the loop
197 * @pre tethering_foreach_connected_clients() will invoke this callback.
198 * @see tethering_foreach_connected_clients()
200 typedef bool(*tethering_connected_client_cb)(tethering_client_h client, void *user_data);
203 * @brief Called when you get the data usage.
205 * @param[in] result The result of getting the data usage
206 * @param[in] received_data The usage of received data
207 * @param[in] sent_data The usage of sent data
208 * @param[in] user_data The user data passed from the request function
209 * @pre tethering_get_data_usage() will invoked this callback.
211 typedef void (*tethering_data_usage_cb)(tethering_error_e result, unsigned long long received_data, unsigned long long sent_data, void *user_data);
214 * @brief Called when the security type of Wi-Fi tethering is changed.
216 * @param[in] changed_type The changed security type of Wi-Fi tethering
217 * @param[in] user_data The user data passed from the register function
218 * @see tethering_wifi_set_security_type_changed_cb()
219 * @see tethering_wifi_unset_security_type_changed_cb()
221 typedef void (*tethering_wifi_security_type_changed_cb)(tethering_wifi_security_type_e changed_type, void *user_data);
224 * @brief Called when the visibility of SSID is changed.
226 * @param[in] changed_visible The changed visibility of SSID
227 * @param[in] user_data The user data passed from the register function
228 * @see tethering_wifi_set_ssid_visibility_changed_cb()
229 * @see tethering_wifi_unset_ssid_visibility_changed_cb()
231 typedef void (*tethering_wifi_ssid_visibility_changed_cb)(bool changed_visible, void *user_data);
234 * @brief Called when the passphrase of Wi-Fi tethering is changed.
236 * @param[in] user_data The user data passed from the register function
237 * @see tethering_wifi_set_passphrase_changed_cb()
238 * @see tethering_wifi_unset_passphrase_changed_cb()
240 typedef void (*tethering_wifi_passphrase_changed_cb)(void *user_data);
243 * @brief Called when the settings are reloaded.
245 * @param[in] result The result of reloading the settings
246 * @param[in] user_data The user data passed from the request function
247 * @pre tethering_wifi_reload_settings() will invoke this callback.
249 typedef void (*tethering_wifi_settings_reloaded_cb)(tethering_error_e result, void *user_data);
252 * @brief Creates the handle for tethering.
254 * @privlevel platform
255 * @privilege %http://tizen.org/privilege/tethering.admin
256 * @remarks The @a tethering must be released using tethering_destroy().
257 * @param[out] tethering A handle of a new mobile ap handle on success
258 * @return 0 on success, otherwise a negative error value
259 * @retval #TETHERING_ERROR_NONE Successful
260 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
261 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
262 * @retval #TETHERING_ERROR_NOT_SUPPORT_API API is not supported
263 * @see tethering_destroy()
265 int tethering_create(tethering_h *tethering);
268 * @brief Destroys the handle for tethering.
270 * @privlevel platform
271 * @privilege %http://tizen.org/privilege/tethering.admin
272 * @param[in] tethering The tethering handle
273 * @return 0 on success, otherwise a negative error value
274 * @retval #TETHERING_ERROR_NONE Successful
275 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
276 * @see tethering_create()
278 int tethering_destroy(tethering_h tethering);
281 * @brief Enables the tethering, asynchronously.
283 * @privlevel platform
284 * @privilege %http://tizen.org/privilege/tethering.admin
285 * @param[in] tethering The tethering handle
286 * @param[in] type The tethering type
287 * @return 0 on success, otherwise negative error value
288 * @retval #TETHERING_ERROR_NONE Successful
289 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
290 * @post tethering_enabled_cb() will be invoked.
291 * @see tethering_is_enabled()
292 * @see tethering_disable()
294 int tethering_enable(tethering_h tethering, tethering_type_e type);
297 * @brief Disables the tethering, asynchronously.
299 * @privlevel platform
300 * @privilege %http://tizen.org/privilege/tethering.admin
301 * @param[in] tethering The tethering handle
302 * @param[in] type The tethering type
303 * @return 0 on success, otherwise negative error value
304 * @retval #TETHERING_ERROR_NONE Successful
305 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
306 * @post tethering_disabled_cb() will be invoked.
307 * @see tethering_is_enabled()
308 * @see tethering_enable()
310 int tethering_disable(tethering_h tethering, tethering_type_e type);
313 * @brief Checks whether the tethering is enabled or not.
315 * @privlevel platform
316 * @privilege %http://tizen.org/privilege/tethering.admin
317 * @param[in] tethering The tethering handle
318 * @param[in] type The tethering type
319 * @return @c true if tethering is enabled, \n @c false if tethering is disabled
321 bool tethering_is_enabled(tethering_h tethering, tethering_type_e type);
324 * @brief Gets the MAC address of local device as "FC:A1:3E:D6:B1:B1".
326 * @privlevel platform
327 * @privilege %http://tizen.org/privilege/tethering.admin
328 * @remarks @a mac_address must be released using free().
329 * @param[in] tethering The tethering handle
330 * @param[in] type The tethering type
331 * @param[out] mac_address The MAC address
332 * @return 0 on success, otherwise a negative error value
333 * @retval #TETHERING_ERROR_NONE Successful
334 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
335 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
336 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
337 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
338 * @pre The tethering must be enabled.
339 * @see tethering_is_enabled()
340 * @see tethering_enable()
342 int tethering_get_mac_address(tethering_h tethering, tethering_type_e type, char **mac_address);
345 * @brief Gets the name of network interface (e.g. usb0).
347 * @privlevel platform
348 * @privilege %http://tizen.org/privilege/tethering.admin
349 * @remarks @a interface_name must be released using free().
350 * @param[in] tethering The tethering handle
351 * @param[in] type The tethering type
352 * @param[out] interface_name The name of the network interface
353 * @return 0 on success, otherwise negative error value
354 * @retval #TETHERING_ERROR_NONE Successful
355 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
356 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
357 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
358 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
359 * @pre The tethering must be enabled.
360 * @see tethering_is_enabled()
361 * @see tethering_enable()
363 int tethering_get_network_interface_name(tethering_h tethering, tethering_type_e type, char **interface_name);
366 * @brief Gets the local IP address.
368 * @privlevel platform
369 * @privilege %http://tizen.org/privilege/tethering.admin
370 * @remarks @a ip_address must be released using free().
371 * @param[in] tethering The tethering handle
372 * @param[in] type The tethering type
373 * @param[in] address_family The address family of IP address (currently, #TETHERING_ADDRESS_FAMILY_IPV4 is only supported)
374 * @param[out] ip_address The local IP address
375 * @return 0 on success, otherwise negative error value
376 * @retval #TETHERING_ERROR_NONE Successful
377 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
378 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
379 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
380 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
381 * @pre The tethering must be enabled.
382 * @see tethering_is_enabled()
383 * @see tethering_enable()
385 int tethering_get_ip_address(tethering_h tethering, tethering_type_e type, tethering_address_family_e address_family, char **ip_address);
388 * @brief Gets the Gateway address.
390 * @privlevel platform
391 * @privilege %http://tizen.org/privilege/tethering.admin
392 * @remarks @a gateway_address must be released using free().
393 * @param[in] tethering The tethering handle
394 * @param[in] type The tethering type
395 * @param[in] address_family The address family of IP address (currently, #TETHERING_ADDRESS_FAMILY_IPV4 is only supported)
396 * @param[out] gateway_address The local IP address
397 * @return 0 on success, otherwise negative error value
398 * @retval #TETHERING_ERROR_NONE Successful
399 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
400 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
401 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
402 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
403 * @pre The tethering must be enabled.
404 * @see tethering_is_enabled()
405 * @see tethering_enable()
407 int tethering_get_gateway_address(tethering_h tethering, tethering_type_e type, tethering_address_family_e address_family, char **gateway_address);
410 * @brief Gets the Subnet Mask.
412 * @privlevel platform
413 * @privilege %http://tizen.org/privilege/tethering.admin
414 * @remarks @a subnet_mask must be released using free().
415 * @param[in] tethering The tethering handle
416 * @param[in] type The tethering type
417 * @param[in] address_family The address family of IP address (currently, #TETHERING_ADDRESS_FAMILY_IPV4 is only supported)
418 * @param[out] subnet_mask The local IP address
419 * @return 0 on success, otherwise negative error value
420 * @retval #TETHERING_ERROR_NONE Successful
421 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
422 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
423 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
424 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
425 * @pre The tethering must be enabled.
426 * @see tethering_is_enabled()
427 * @see tethering_enable()
429 int tethering_get_subnet_mask(tethering_h tethering, tethering_type_e type, tethering_address_family_e address_family, char **subnet_mask);
432 * @brief Gets the data usage.
434 * @privlevel platform
435 * @privilege %http://tizen.org/privilege/tethering.admin
436 * @param[in] tethering The tethering handle
437 * @param[out] usage The data usage
438 * @return 0 on success, otherwise negative error value
439 * @retval #TETHERING_ERROR_NONE Successful
440 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
441 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
442 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
443 * @pre The tethering must be enabled.
444 * @see tethering_is_enabled()
445 * @see tethering_enable()
447 int tethering_get_data_usage(tethering_h tethering, tethering_data_usage_cb callback, void *user_data);
450 * @brief Gets the clients which are connected.
452 * @privlevel platform
453 * @privilege %http://tizen.org/privilege/tethering.admin
454 * @param[in] tethering The tethering handle
455 * @param[in] type The tethering type
456 * @param[in] callback The callback function to invoke
457 * @param[in] user_data The user data to be passed to the callback function
458 * @retval #TETHERING_ERROR_NONE Successful
459 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
460 * @retval #TETHERING_ERROR_NOT_ENABLED Not enabled
461 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
462 * @pre The tethering must be enabled.
463 * @see tethering_is_enabled()
464 * @see tethering_enable()
466 int tethering_foreach_connected_clients(tethering_h tethering, tethering_type_e type, tethering_connected_client_cb callback, void *user_data);
469 * @brief Registers the callback function, which is called when tethering is enabled.
471 * @privlevel platform
472 * @privilege %http://tizen.org/privilege/tethering.admin
473 * @param[in] tethering The tethering handle
474 * @param[in] type The tethering type
475 * @param[in] callback The callback function to invoke
476 * @param[in] user_data The user data to be passed to the callback function
477 * @retval #TETHERING_ERROR_NONE Successful
478 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
479 * @see tethering_unset_enabled_cb()
481 int tethering_set_enabled_cb(tethering_h tethering, tethering_type_e type, tethering_enabled_cb callback, void *user_data);
484 * @brief Unregisters the callback function, which is called when tethering is enabled.
486 * @privlevel platform
487 * @privilege %http://tizen.org/privilege/tethering.admin
488 * @param[in] tethering The tethering handle
489 * @param[in] type The tethering type
490 * @retval #TETHERING_ERROR_NONE Successful
491 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
492 * @see tethering_set_enabled_cb()
494 int tethering_unset_enabled_cb(tethering_h tethering, tethering_type_e type);
497 * @brief Registers the callback function called when tethering is disabled.
499 * @privlevel platform
500 * @privilege %http://tizen.org/privilege/tethering.admin
501 * @param[in] tethering The tethering handle
502 * @param[in] type The tethering type
503 * @param[in] callback The callback function to invoke
504 * @param[in] user_data The user data to be passed to the callback function
505 * @retval #TETHERING_ERROR_NONE Successful
506 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
507 * @see tethering_unset_disabled_cb()
509 int tethering_set_disabled_cb(tethering_h tethering, tethering_type_e type, tethering_disabled_cb callback, void *user_data);
512 * @brief Unregisters the callback function, which is called when tethering is disabled.
514 * @privlevel platform
515 * @privilege %http://tizen.org/privilege/tethering.admin
516 * @param[in] tethering The tethering handle
517 * @param[in] type The tethering type
518 * @retval #TETHERING_ERROR_NONE Successful
519 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
520 * @see tethering_set_disabled_cb()
522 int tethering_unset_disabled_cb(tethering_h tethering, tethering_type_e type);
525 * @brief Registers the callback function, which is called when the state of connection is changed.
527 * @privlevel platform
528 * @privilege %http://tizen.org/privilege/tethering.admin
529 * @param[in] tethering The tethering handle
530 * @param[in] type The tethering type
531 * @param[in] callback The callback function to invoke
532 * @param[in] user_data The user data to be passed to the callback function
533 * @retval #TETHERING_ERROR_NONE Successful
534 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
535 * @see tethering_unset_connection_state_changed_cb_cb()
537 int tethering_set_connection_state_changed_cb(tethering_h tethering, tethering_type_e type, tethering_connection_state_changed_cb callback, void *user_data);
540 * @brief Unregisters the callback function, which is called when the state of connection is changed.
542 * @privlevel platform
543 * @privilege %http://tizen.org/privilege/tethering.admin
544 * @param[in] tethering The tethering handle
545 * @param[in] type The tethering type
546 * @retval #TETHERING_ERROR_NONE Successful
547 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
548 * @see tethering_set_connection_state_changed_cb()
550 int tethering_unset_connection_state_changed_cb(tethering_h tethering, tethering_type_e type);
553 * @brief Registers the callback function, which is called when the security type of Wi-Fi tethering is changed.
555 * @privlevel platform
556 * @privilege %http://tizen.org/privilege/tethering.admin
557 * @param[in] tethering The tethering handle
558 * @param[in] callback The callback function to invoke
559 * @param[in] user_data The user data to be passed to the callback function
560 * @retval #TETHERING_ERROR_NONE Successful
561 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
562 * @see tethering_wifi_unset_security_type_changed_cb()
564 int tethering_wifi_set_security_type_changed_cb(tethering_h tethering, tethering_wifi_security_type_changed_cb callback, void *user_data);
567 * @brief Unregisters the callback function, which is called when the security type of Wi-Fi tethering is changed.
569 * @privlevel platform
570 * @privilege %http://tizen.org/privilege/tethering.admin
571 * @param[in] tethering The tethering handle
572 * @param[in] type The tethering type
573 * @retval #TETHERING_ERROR_NONE Successful
574 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
575 * @see tethering_wifi_set_security_type_changed_cb()
577 int tethering_wifi_unset_security_type_changed_cb(tethering_h tethering);
580 * @brief Registers the callback function , which iscalled when the visibility of SSID is changed.
582 * @privlevel platform
583 * @privilege %http://tizen.org/privilege/tethering.admin
584 * @param[in] tethering The tethering handle
585 * @param[in] callback The callback function to invoke
586 * @param[in] user_data The user data to be passed to the callback function
587 * @retval #TETHERING_ERROR_NONE Successful
588 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
589 * @see tethering_wifi_unset_ssid_visibility_changed_cb_cb()
591 int tethering_wifi_set_ssid_visibility_changed_cb(tethering_h tethering, tethering_wifi_ssid_visibility_changed_cb callback, void *user_data);
594 * @brief Unregisters the callback function, which is called when the visibility of SSID is changed.
596 * @privlevel platform
597 * @privilege %http://tizen.org/privilege/tethering.admin
598 * @param[in] tethering The tethering handle
599 * @retval #TETHERING_ERROR_NONE Successful
600 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
601 * @see tethering_wifi_set_ssid_visibility_changed_cb()
603 int tethering_wifi_unset_ssid_visibility_changed_cb(tethering_h tethering);
606 * @brief Registers the callback function, which is called when the passphrase of Wi-Fi tethering is changed.
608 * @privlevel platform
609 * @privilege %http://tizen.org/privilege/tethering.admin
610 * @param[in] tethering The tethering handle
611 * @param[in] callback The callback function to invoke
612 * @param[in] user_data The user data to be passed to the callback function
613 * @retval #TETHERING_ERROR_NONE Successful
614 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
615 * @see tethering_wifi_unset_passphrase_changed_cb()
617 int tethering_wifi_set_passphrase_changed_cb(tethering_h tethering, tethering_wifi_passphrase_changed_cb callback, void *user_data);
620 * @brief Unregisters the callback function, which is called when the passphrase of Wi-Fi tethering is changed.
622 * @privlevel platform
623 * @privilege %http://tizen.org/privilege/tethering.admin
624 * @param[in] tethering The tethering handle
625 * @retval #TETHERING_ERROR_NONE Successful
626 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
627 * @see tethering_wifi_set_passphrase_changed_cb()
629 int tethering_wifi_unset_passphrase_changed_cb(tethering_h tethering);
637 * @addtogroup CAPI_NETWORK_TETHERING_WIFI_MODULE
642 * @brief Sets the security type of Wi-Fi tethering.
644 * @privlevel platform
645 * @privilege %http://tizen.org/privilege/tethering.admin
646 * @remarks This change is applied next time Wi-Fi tethering is enabled.
647 * @param[in] tethering The tethering handle
648 * @param[in] type The security type
649 * @return 0 on success, otherwise negative error value
650 * @retval #TETHERING_ERROR_NONE Successful
651 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
652 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
653 * @see tethering_wifi_get_security_type()
655 int tethering_wifi_set_security_type(tethering_h tethering, tethering_wifi_security_type_e type);
658 * @brief Gets the security type of Wi-Fi tethering.
660 * @privlevel platform
661 * @privilege %http://tizen.org/privilege/tethering.admin
662 * @param[in] tethering The tethering handle
663 * @param[out] type The security type
664 * @return 0 on success, otherwise negative error value
665 * @retval #TETHERING_ERROR_NONE Successful
666 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
667 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
668 * @see tethering_wifi_set_security_type()
670 int tethering_wifi_get_security_type(tethering_h tethering, tethering_wifi_security_type_e *type);
673 * @brief Sets the SSID (service set identifier).
674 * @details The SSID cannot exceed 32 bytes. If SSID is not set, device name is used as SSID.
676 * @privlevel platform
677 * @privilege %http://tizen.org/privilege/tethering.admin
678 * @remarks This change is applied next time Wi-Fi tethering is enabled with same @a tethering handle.
679 * @param[in] tethering The tethering handle
680 * @param[in] ssid The SSID
681 * @return 0 on success, otherwise negative error value
682 * @retval #TETHERING_ERROR_NONE Successful
683 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
684 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
686 int tethering_wifi_set_ssid(tethering_h tethering, const char *ssid);
689 * @brief Gets the SSID (service set identifier).
691 * @privlevel platform
692 * @privilege %http://tizen.org/privilege/tethering.admin
693 * @remarks @a ssid must be released using free().
694 * @param[in] tethering The tethering handle
695 * @param[out] ssid The SSID
696 * @return 0 on success, otherwise negative error value
697 * @retval #TETHERING_ERROR_NONE Successful
698 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
699 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
700 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
702 int tethering_wifi_get_ssid(tethering_h tethering, char **ssid);
705 * @brief Sets the visibility of SSID (service set identifier).
706 * @details If the visibility is set to invisible, then the SSID of this device is hidden and Wi-Fi scan will not find the device.
708 * @privlevel platform
709 * @privilege %http://tizen.org/privilege/tethering.admin
710 * @remarks This change is applied next time Wi-Fi tethering is enabled.
711 * @param[in] tethering The tethering handle
712 * @param[in] visible The visibility of SSID: (@c true = visible, @c false = invisible)
713 * @return 0 on success, otherwise negative error value
714 * @retval #TETHERING_ERROR_NONE Successful
715 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
716 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
717 * @see tethering_wifi_get_ssid_visibility()
719 int tethering_wifi_set_ssid_visibility(tethering_h tethering, bool visible);
722 * @brief Gets the visibility of SSID (service set identifier).
723 * @details If the visibility is set to invisible, then the SSID of this device is hidden and Wi-Fi scan will not find the device.
725 * @privlevel platform
726 * @privilege %http://tizen.org/privilege/tethering.admin
727 * @param[in] tethering The tethering handle
728 * @param[out] visible The visibility of SSID: (@c true = visible, @c false = invisible)
729 * @return 0 on success, otherwise negative error value
730 * @retval #TETHERING_ERROR_NONE Successful
731 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
732 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
733 * @see tethering_wifi_set_ssid_visibility()
735 int tethering_wifi_get_ssid_visibility(tethering_h tethering, bool *visible);
738 * @brief Sets the passphrase.
740 * @privlevel platform
741 * @privilege %http://tizen.org/privilege/tethering.admin
742 * @remarks This change is applied next time Wi-Fi tethering is enabled.
743 * @param[in] tethering The tethering handle
744 * @param[in] passphrase The passphrase
745 * @return 0 on success, otherwise negative error value
746 * @retval #TETHERING_ERROR_NONE Successful
747 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
748 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
749 * @see tethering_wifi_get_passphrase()
751 int tethering_wifi_set_passphrase(tethering_h tethering, const char *passphrase);
754 * @brief Gets the passphrase.
756 * @privlevel platform
757 * @privilege %http://tizen.org/privilege/tethering.admin
758 * @remarks @a passphrase must be released using free().
759 * @param[in] tethering The tethering handle
760 * @param[out] passphrase The passphrase
761 * @return 0 on success, otherwise negative error value
762 * @retval #TETHERING_ERROR_NONE Successful
763 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
764 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
765 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
766 * @see tethering_wifi_set_passphrase()
768 int tethering_wifi_get_passphrase(tethering_h tethering, char **passphrase);
771 * @brief Reloads the settings (SSID / Passphrase / Security type / SSID visibility).
773 * @privlevel platform
774 * @privilege %http://tizen.org/privilege/tethering.admin
775 * @remarks Connected devices via Wi-Fi tethering or MobileAP will be disconnected when the settings are reloaded.
776 * @param[in] tethering The tethering handle
777 * @param[in] callback The callback function to invoke
778 * @param[in] user_data The user data to be passed to the callback function
779 * @return 0 on success, otherwise negative error value
780 * @retval #TETHERING_ERROR_NONE Successful
781 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
782 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
784 int tethering_wifi_reload_settings(tethering_h tethering, tethering_wifi_settings_reloaded_cb callback, void *user_data);
787 * @brief Gets the mac_filter for Wi-Fi Tethering.
788 * @details If you set the mac_filter to enable, then the device can be allowed/blocked based on mac-address.
789 * By default mac_filter is set to false.
791 * @privlevel platform
792 * @privilege %http://tizen.org/privilege/tethering.admin
793 * @param[in] tethering The handle of tethering
794 * @param[out] mac_filter The mac filter: (@c true = enable, @c false = disable)
795 * @return 0 on success, otherwise negative error value.
796 * @retval #TETHERING_ERROR_NONE Successful
797 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
798 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
799 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
800 * @see tethering_mobileap_set_mac_filter()
802 int tethering_wifi_get_mac_filter(tethering_h tethering, bool *mac_filter);
805 * @brief Sets the mac-filter for Wi-Fi Tethering.
806 * @details If you set the mac_filter to enable, then the device can be allowed/blocked based on mac-address.
807 * By default mac_filter is set to @c false.
809 * @privlevel platform
810 * @privilege %http://tizen.org/privilege/tethering.admin
811 * @remarks This change is applied next time Wi-Fi tethering is enabled.
812 * @param[in] tethering The tethering handle
813 * @param[in] mac_filter The mac filter: (@c true = enable, @c false = disable)
814 * @return 0 on success, otherwise negative error value
815 * @retval #TETHERING_ERROR_NONE Successful
816 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
817 * @retval #TETHERING_ERROR_OPERATION_FAILED Operation failed
818 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
819 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
820 * @see tethering_mobileap_get_mac_filter()
822 int tethering_wifi_set_mac_filter(tethering_h tethering, bool mac_filter);
825 * @brief Adds the mac-address to the allowed client list.
826 * @details AP can allow the client by adding clients mac-address to the allowed list.
828 * @privlevel platform
829 * @privilege %http://tizen.org/privilege/tethering.admin
830 * @param[in] tethering The handle of tethering
831 * @param[in] mac The mac address
832 * @return 0 on success, otherwise negative error value.
833 * @retval #TETHERING_ERROR_NONE Successful
834 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
835 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
836 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
837 * @see tethering_mobileap_set_mac_filter()
839 int tethering_wifi_add_allowed_mac_list(tethering_h tethering, const char *mac);
842 * @brief Removes the mac-address from the allowed client list.
843 * @details Removes the mac-address from the allowed client list.
845 * @privlevel platform
846 * @privilege %http://tizen.org/privilege/tethering.admin
847 * @param[in] tethering The handle of tethering
848 * @param[in] mac The mac address
849 * @return 0 on success, otherwise negative error value.
850 * @retval #TETHERING_ERROR_NONE Successful
851 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
852 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
853 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
854 * @see tethering_mobileap_set_mac_filter()
856 int tethering_wifi_remove_allowed_mac_list(tethering_h tethering, const char *mac);
858 * @brief Gets the mac-addresses from the allowed client list.
859 * @details Gets the mac-addresses from the allowed client list.
861 * @privlevel platform
862 * @privilege %http://tizen.org/privilege/tethering.admin
863 * @param[in] tethering The handle of tethering
864 * @param[out] allowed_mac_list list of allowed mac addresses list
865 * @return 0 on success, otherwise negative error value.
866 * @retval #TETHERING_ERROR_NONE Successful
867 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
868 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
869 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
870 * @see tethering_mobileap_set_mac_filter()
872 int tethering_wifi_get_allowed_mac_list(tethering_h tethering, void **allowed_mac_list);
875 * @brief Adds the mac-address to the blocked(black list) client list.
876 * @details AP can disallow the client by adding clients mac-address to the blocked list.
878 * @privlevel platform
879 * @privilege %http://tizen.org/privilege/tethering.admin
880 * @param[in] tethering The handle of tethering
881 * @param[in] mac The mac address
882 * @return 0 on success, otherwise negative error value.
883 * @retval #TETHERING_ERROR_NONE Successful
884 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
885 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
886 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
887 * @see tethering_mobileap_set_mac_filter()
889 int tethering_wifi_add_blocked_mac_list(tethering_h tethering, const char *mac);
892 * @brief Removes the mac-address from the blocked(black list) client list.
893 * @details Removes the mac-address from the blocked client list.
895 * @privlevel platform
896 * @privilege %http://tizen.org/privilege/tethering.admin
897 * @param[in] tethering The handle of tethering
898 * @param[in] mac The mac address
899 * @return 0 on success, otherwise negative error value.
900 * @retval #TETHERING_ERROR_NONE Successful
901 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
902 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
903 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
904 * @see tethering_mobileap_set_mac_filter()
906 int tethering_wifi_remove_blocked_mac_list(tethering_h tethering, const char *mac);
909 * @brief Gets the mac-addresses from the blocked client list.
910 * @details Get the mac-addresses from the blocked client list.
912 * @privlevel platform
913 * @privilege %http://tizen.org/privilege/tethering.admin
914 * @param[in] tethering The handle of tethering
915 * @param[out] blocked_mac_list list of blocked mac addresses list
916 * @return 0 on success, otherwise negative error value.
917 * @retval #TETHERING_ERROR_NONE Successful
918 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
919 * @retval #TETHERING_ERROR_NOT_SUPPORTED API is not supported
920 * @retval #TETHERING_ERROR_PERMISSION_DENIED Permission Denied
921 * @see tethering_mobileap_set_mac_filter()
923 int tethering_wifi_get_blocked_mac_list(tethering_h tethering, void **blocked_mac_list);
926 * @brief Enables/disables the dhcp server.
928 * @privlevel platform
929 * @privilege %http://tizen.org/privilege/tethering.admin
930 * @details Enable/disable the dhcp server.
931 * @param[in] tethering The handle of tethering
932 * @param[in] enable Enable/disable the dhcp server
933 * @return 0 on success, otherwise negative error value.
934 * @retval #TETHERING_ERROR_NONE Successful
935 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
937 int tethering_wifi_enable_dhcp(tethering_h tethering, bool enable);
940 * @brief Enables the dhcp server with the address range.
942 * @privlevel platform
943 * @privilege %http://tizen.org/privilege/tethering.admin
944 * @details Enable the dhcp server with the address range.
945 * @param[in] tethering The handle of tethering
946 * @param[in] rangestart Start address range
947 * @param[in] rangestop End address range
948 * @return 0 on success, otherwise negative error value.
949 * @retval #TETHERING_ERROR_NONE Successful
950 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
952 int tethering_wifi_set_dhcp_range(tethering_h tethering, char *rangestart, char *rangestop);
955 * @brief Checks whether the dhcp is enabled or not.
957 * @privlevel platform
958 * @privilege %http://tizen.org/privilege/tethering.admin
959 * @param[in] tethering The tethering handle
960 * @param[out] dhcp_enabled @c true if dhcp is enabled, \n @c false if dhcp is disabled
961 * @return 0 on success, otherwise a negative error value
962 * @retval #TETHERING_ERROR_NONE Successful
963 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
965 int tethering_wifi_is_dhcp_enabled(tethering_h tethering, bool *dhcp_enabled);
968 * @brief Sets the Channel for Wi-Fi.
969 * @details The Channel should be in between 1-14. If channel is not set, Wi-Fi sets default channel.
971 * @privlevel platform
972 * @privilege %http://tizen.org/privilege/tethering.admin
973 * @param[in] tethering The tethering handle
974 * @param[in] channel The channel number
975 * @return 0 on success, otherwise negative error value
976 * @retval #TETHERING_ERROR_NONE Successful
977 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
979 int tethering_wifi_set_channel(tethering_h tethering, int channel);
982 * @brief Gets the channel for Wi-Fi.
983 * @details If channel is not set, Wi-Fi gets default channel.
985 * @privlevel platform
986 * @privilege %http://tizen.org/privilege/tethering.admin
987 * @param[in] tethering The tethering handle
988 * @param[out] channel The channel number
989 * @return 0 on success, otherwise negative error value
990 * @retval #TETHERING_ERROR_NONE Successful
991 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
992 * @see tethering_wifi_set_channel()
994 int tethering_wifi_get_channel(tethering_h tethering, int *channel);
997 * @brief Sets the mode for Wi-Fi.
998 * @details The mobile AP mode (ex: b only, g only, ad, a). If mode is not set, Wi-Fi sets default mode.
1000 * @privlevel platform
1001 * @privilege %http://tizen.org/privilege/tethering.admin
1002 * @param[in] tethering The tethering handle
1003 * @param[in] type The mobile AP mode
1004 * @return 0 on success, otherwise negative error value
1005 * @retval #TETHERING_ERROR_NONE Successful
1006 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1008 int tethering_wifi_set_mode(tethering_h tethering, tethering_wifi_mode_type_e type);
1011 * @brief Gets the mode for Wi-Fi.
1012 * @details If the mode is not set, Wi-Fi gets default mode.
1014 * @privlevel platform
1015 * @privilege %http://tizen.org/privilege/tethering.admin
1016 * @remarks @a mode must be released using free().
1017 * @param[in] tethering The tethering handle
1018 * @param[out] type The mode of Wi-Fi AP
1019 * @return 0 on success, otherwise negative error value
1020 * @retval #TETHERING_ERROR_NONE Successful
1021 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1022 * @see tethering_wifi_set_mode()
1024 int tethering_wifi_get_mode(tethering_h tethering, tethering_wifi_mode_type_e *type);
1032 * @addtogroup CAPI_NETWORK_TETHERING_CLIENT_MODULE
1037 * @brief Clones the handle of a client.
1039 * @privlevel platform
1040 * @privilege %http://tizen.org/privilege/tethering.admin
1041 * @remarks @a dest must be release using tethering_client_destroy().
1042 * @param[out] dest The cloned client handle
1043 * @param[in] origin The origin client handle
1044 * @return 0 on success, otherwise a negative error value
1045 * @retval #TETHERING_ERROR_NONE Successful
1046 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1047 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
1048 * @see tethering_client_destroy()
1050 int tethering_client_clone(tethering_client_h *dest, tethering_client_h origin);
1053 * @brief Destroys the handle of a client.
1055 * @privlevel platform
1056 * @privilege %http://tizen.org/privilege/tethering.admin
1057 * @param[in] client The client handle
1058 * @return 0 on success, otherwise a negative error value
1059 * @retval #TETHERING_ERROR_NONE Successful
1060 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1061 * @see tethering_client_clone()
1063 int tethering_client_destroy(tethering_client_h client);
1066 * @brief Gets the tethering type of client.
1068 * @privlevel platform
1069 * @privilege %http://tizen.org/privilege/tethering.admin
1070 * @param[in] client The handle of client
1071 * @param[out] type The type of tethering
1072 * @return 0 on success, otherwise a negative error value.
1073 * @retval #TETHERING_ERROR_NONE Successful
1074 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1075 * @see tethering_usb_get_connected_client()
1076 * @see tethering_connection_state_changed_cb()
1078 int tethering_client_get_tethering_type(tethering_client_h client, tethering_type_e *type);
1081 * @brief Gets the name of a client.
1083 * @privlevel platform
1084 * @privilege %http://tizen.org/privilege/tethering.admin
1085 * @remarks @a name must be released using free().
1086 * @param[in] client The client handle
1087 * @param[out] name The name of the client
1088 * @return 0 on success, otherwise a negative error value
1089 * @retval #TETHERING_ERROR_NONE Successful
1090 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1091 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
1092 * @see tethering_usb_get_connected_client()
1093 * @see tethering_connection_state_changed_cb()
1095 int tethering_client_get_name(tethering_client_h client, char **name);
1098 * @brief Gets the IP address of a client.
1100 * @privlevel platform
1101 * @privilege %http://tizen.org/privilege/tethering.admin
1102 * @remarks @a ip_address must be released using free().
1103 * @param[in] client The client handle
1104 * @param[in] address_family The address family of IP address. Currently, #TETHERING_ADDRESS_FAMILY_IPV4 is only supported
1105 * @param[out] ip_address The IP address
1106 * @return 0 on success, otherwise a negative error value
1107 * @retval #TETHERING_ERROR_NONE Successful
1108 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1109 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
1110 * @see tethering_usb_get_connected_client()
1111 * @see tethering_connection_state_changed_cb()
1113 int tethering_client_get_ip_address(tethering_client_h client, tethering_address_family_e address_family, char **ip_address);
1116 * @brief Gets the MAC address of a client such as "FC:A1:3E:D6:B1:B1".
1118 * @privlevel platform
1119 * @privilege %http://tizen.org/privilege/tethering.admin
1120 * @remarks @a mac_address must be released using free().
1121 * @param[in] client The client handle
1122 * @param[out] mac_address The MAC address
1123 * @return 0 on success, otherwise a negative error value
1124 * @retval #TETHERING_ERROR_NONE Successful
1125 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1126 * @retval #TETHERING_ERROR_OUT_OF_MEMORY Out of memory
1127 * @see tethering_usb_get_connected_client()
1128 * @see tethering_connection_state_changed_cb()
1130 int tethering_client_get_mac_address(tethering_client_h client, char **mac_address);
1133 * @brief Gets the connection time of a client.
1135 * @privlevel platform
1136 * @privilege %http://tizen.org/privilege/tethering.admin
1137 * @param[in] client The client handle
1138 * @param[out] time The connected time of the client
1139 * @return 0 on success, otherwise a negative error value
1140 * @retval #TETHERING_ERROR_NONE Successful
1141 * @retval #TETHERING_ERROR_INVALID_PARAMETER Invalid parameter
1142 * @see tethering_usb_get_connected_client()
1143 * @see tethering_connection_state_changed_cb()
1145 int tethering_client_get_time(tethering_client_h client, time_t *timestamp);
1156 #endif /* __TIZEN_NETWORK_TETHERING_H__ */