X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=include%2Fdevice.h;h=57b925c4048fff4db8d7e243863b9b773542ab8f;hb=6f5ffa18c1f8cf226313d9a8c9accb8781bf4a8c;hp=470059b106c425e38a360305843ff75de05c4eb8;hpb=287c19dc6093d7b55f52741e1af90a742249a534;p=platform%2Fupstream%2Fconnman.git diff --git a/include/device.h b/include/device.h old mode 100644 new mode 100755 index 470059b..57b925c --- a/include/device.h +++ b/include/device.h @@ -2,7 +2,7 @@ * * Connection Manager * - * Copyright (C) 2007-2012 Intel Corporation. All rights reserved. + * Copyright (C) 2007-2014 Intel Corporation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as @@ -22,8 +22,8 @@ #ifndef __CONNMAN_DEVICE_H #define __CONNMAN_DEVICE_H -#include #include +#include #ifdef __cplusplus extern "C" { @@ -39,11 +39,10 @@ enum connman_device_type { CONNMAN_DEVICE_TYPE_UNKNOWN = 0, CONNMAN_DEVICE_TYPE_ETHERNET = 1, CONNMAN_DEVICE_TYPE_WIFI = 2, - CONNMAN_DEVICE_TYPE_WIMAX = 3, - CONNMAN_DEVICE_TYPE_BLUETOOTH = 4, - CONNMAN_DEVICE_TYPE_CELLULAR = 5, - CONNMAN_DEVICE_TYPE_GPS = 6, - CONNMAN_DEVICE_TYPE_GADGET = 7, + CONNMAN_DEVICE_TYPE_BLUETOOTH = 3, + CONNMAN_DEVICE_TYPE_CELLULAR = 4, + CONNMAN_DEVICE_TYPE_GPS = 5, + CONNMAN_DEVICE_TYPE_GADGET = 6, CONNMAN_DEVICE_TYPE_VENDOR = 10000, }; @@ -79,16 +78,16 @@ void connman_device_set_ident(struct connman_device *device, const char *connman_device_get_ident(struct connman_device *device); int connman_device_set_powered(struct connman_device *device, - connman_bool_t powered); -connman_bool_t connman_device_get_powered(struct connman_device *device); + bool powered); +bool connman_device_get_powered(struct connman_device *device); int connman_device_set_scanning(struct connman_device *device, - connman_bool_t scanning); -connman_bool_t connman_device_get_scanning(struct connman_device *device); + enum connman_service_type type, bool scanning); +bool connman_device_get_scanning(struct connman_device *device); void connman_device_reset_scanning(struct connman_device *device); int connman_device_set_disconnected(struct connman_device *device, - connman_bool_t disconnected); -connman_bool_t connman_device_get_disconnected(struct connman_device *device); + bool disconnected); +bool connman_device_get_disconnected(struct connman_device *device); int connman_device_set_string(struct connman_device *device, const char *key, const char *value); @@ -101,7 +100,6 @@ struct connman_network *connman_device_get_network(struct connman_device *device const char *identifier); int connman_device_remove_network(struct connman_device *device, struct connman_network *network); -void connman_device_remove_all_networks(struct connman_device *device); int connman_device_register(struct connman_device *device); void connman_device_unregister(struct connman_device *device); @@ -113,6 +111,9 @@ int connman_device_set_regdom(struct connman_device *device, const char *alpha2); void connman_device_regdom_notify(struct connman_device *device, int result, const char *alpha2); +struct connman_device *connman_device_create_from_index(int index); +struct connman_device *connman_device_find_by_index(int index); +int connman_device_reconnect_service(struct connman_device *device); struct connman_device_driver { const char *name; @@ -122,10 +123,11 @@ struct connman_device_driver { void (*remove) (struct connman_device *device); int (*enable) (struct connman_device *device); int (*disable) (struct connman_device *device); - int (*scan)(struct connman_device *device, + int (*scan)(enum connman_service_type type, + struct connman_device *device, const char *ssid, unsigned int ssid_len, const char *identity, const char* passphrase, - void *user_data); + const char *security, void *user_data); int (*set_regdom) (struct connman_device *device, const char *alpha2); };