Knox Tizen Wearable SDK
|
Bluetooth policy group provides policies for bluetooth control. More...
Enumerations |
Functions | |
mdm_data_t * | mdm_get_bluetooth_bonded_device_list (void) |
API to get a list of the bonded (paired) devices to the local adapter. More... | |
mdm_result_t | mdm_set_allow_bluetooth_mode (mdm_bt_allow_t state) |
API to set the Bluetooth capability mode on the device. More... | |
mdm_bt_allow_t | mdm_get_allow_bluetooth_mode (void) |
API to check whether the mode of the Bluetooth capability is allowed, restricted, or set as "hands-free only". More... | |
mdm_result_t | mdm_set_allow_bluetooth_outgoing_call (mdm_status_t value) |
API to set whether to allow the transfer of outgoing calls to Bluetooth headsets. More... | |
mdm_status_t | mdm_get_allow_bluetooth_outgoing_call (void) |
API to check whether outgoing calls are allowed via a Bluetooth headset. More... | |
mdm_result_t | mdm_set_bluetooth_profile_state (mdm_status_t state, mdm_bt_profile_t profile) |
API to set the state of a Bluetooth profile. More... | |
mdm_status_t | mdm_get_bluetooth_profile_state (mdm_bt_profile_t profile) |
API to check whether a specific Bluetooth profile is allowed. More... | |
mdm_result_t | mdm_set_bluetooth_discoverable_state (mdm_status_t value) |
API to set whether to allow Bluetooth discovery. More... | |
mdm_status_t | mdm_get_bluetooth_discoverable_state (void) |
API to check whether discoverable mode is allowed. More... | |
mdm_result_t | mdm_set_bluetooth_pairing_state (mdm_status_t value) |
API to set whether to allow Bluetooth pairing with other Bluetooth devices. More... | |
mdm_status_t | mdm_get_bluetooth_pairing_state (void) |
API to check whether Bluetooth pairing is allowed. More... | |
mdm_result_t | mdm_set_bluetooth_data_transfer_state (mdm_status_t value) |
API to set whether to allow data transfer via Bluetooth. More... | |
mdm_status_t | mdm_get_bluetooth_data_transfer_state (void) |
API to get whether data transfer via Bluetooth is allowed. More... | |
mdm_result_t | mdm_add_bluetooth_uuids_to_whitelist (GList *uuids) |
API to add UUIDs to the Bluetooth UUID whitelist. More... | |
mdm_result_t | mdm_remove_bluetooth_uuids_from_whitelist (GList *uuids) |
API to remove UUIDs from the Bluetooth UUID whitelist. More... | |
mdm_result_t | mdm_clear_bluetooth_uuids_from_whitelist (void) |
API to clear all UUIDs from Bluetooth UUID whitelist. More... | |
mdm_data_t * | mdm_get_bluetooth_uuids_from_whitelist (void) |
API to retrieve the list of whitelisted Bluetooth UUIDs for all admins. More... | |
mdm_result_t | mdm_add_bluetooth_uuids_to_blacklist (GList *uuids) |
API to add UUIDs to the Bluetooth UUID blacklist. More... | |
mdm_result_t | mdm_remove_bluetooth_uuids_from_blacklist (GList *uuids) |
API to remove UUIDs from the Bluetooth UUID blacklist. More... | |
mdm_result_t | mdm_clear_bluetooth_uuids_from_blacklist (void) |
API to clear all UUIDs from Bluetooth UUID blacklist. More... | |
mdm_data_t * | mdm_get_bluetooth_uuids_from_blacklist (void) |
API to retrieve the list of blacklisted Bluetooth UUIDs for all admins. More... | |
mdm_result_t | mdm_activate_bluetooth_uuid_restriction (mdm_status_t value) |
API to activate or deactivate Bluetooth UUID restrictions. More... | |
mdm_status_t | mdm_is_bluetooth_uuid_restriction_active (void) |
API to check if Bluetooth UUID restrictions are active. More... | |
mdm_result_t | mdm_add_bluetooth_devices_to_whitelist (GList *devices) |
API to add devices to the Bluetooth device whitelist. More... | |
mdm_result_t | mdm_remove_bluetooth_devices_from_whitelist (GList *devices) |
API to remove devices from the Bluetooth device whitelist. More... | |
mdm_result_t | mdm_clear_bluetooth_devices_from_whitelist (void) |
API to clear all devices from the Bluetooth device whitelist. More... | |
mdm_data_t * | mdm_get_bluetooth_devices_from_whitelist (void) |
API to retrieve the list of whitelisted Bluetooth devices for all admins. More... | |
mdm_result_t | mdm_add_bluetooth_devices_to_blacklist (GList *devices) |
API to add devices to the Bluetooth device blacklist. More... | |
mdm_result_t | mdm_remove_bluetooth_devices_from_blacklist (GList *devices) |
API to remove devices from the Bluetooth device blacklist. More... | |
mdm_result_t | mdm_clear_bluetooth_devices_from_blacklist (void) |
API to remove all devices from Bluetooth device blacklist. More... | |
mdm_data_t * | mdm_get_bluetooth_devices_from_blacklist (void) |
API to retrieve the list of blacklisted Bluetooth devices for all admins. More... | |
mdm_result_t | mdm_activate_bluetooth_device_restriction (mdm_status_t value) |
API to activate or deactivate Bluetooth device restrictions. More... | |
mdm_status_t | mdm_is_bluetooth_device_restriction_active (void) |
API to check if Bluetooth device restrictions are active. More... | |
mdm_result_t | knox_mdm_get_mobile_wearable_connection_status (knox_mdm_mobile_wearable_status_t *status) |
API to get the connection status between a wearable device and a mobile device. More... | |
Bluetooth policy group provides policies for bluetooth control.
Bluetooth policy group.
#include <mdm.h>
This group provides APIs to control the various settings related to Bluetooth. The user cannot overwrite any disabled settings provided by this policy.
Enum type for the wearable connection status.
Definition at line 106 of file bluetooth.h.
enum mdm_bt_allow_t |
Enum type for Bluetooth allowance types.
Enumerator | |
---|---|
MDM_BT_ERROR |
Bluetooth allowance error |
MDM_BT_ALLOWED |
Bluetooth allowance allowed |
MDM_BT_HANDSFREE_ONLY |
Bluetooth allowance handsfree only |
MDM_BT_RESTRICTED |
Bluetooth allowance restricted |
Definition at line 34 of file bluetooth.h.
Enum type for Bluetooth profile changes.
Definition at line 46 of file bluetooth.h.
enum mdm_bt_profile_t |
Enum type for Bluetooth profiles.
Definition at line 76 of file bluetooth.h.
mdm_result_t knox_mdm_get_mobile_wearable_connection_status | ( | knox_mdm_mobile_wearable_status_t * | status | ) |
API to get the connection status between a wearable device and a mobile device.
[out] | status | The API will return one of the following wearable connection states:
|
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_activate_bluetooth_device_restriction | ( | mdm_status_t | value | ) |
API to activate or deactivate Bluetooth device restrictions.
[in] | value | Whether to activate or deactivate the restrictions. Set to MDM_TRUE to activate the restrictions, or set to MDM_FALSE to deactivate the restrictions. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_activate_bluetooth_uuid_restriction | ( | mdm_status_t | value | ) |
API to activate or deactivate Bluetooth UUID restrictions.
[in] | value | Whether to activate or deactivate the restrictions. Set to MDM_TRUE to activate the restrictions, or set to MDM_FALSE to deactivate the restrictions. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_add_bluetooth_devices_to_blacklist | ( | GList * | devices | ) |
API to add devices to the Bluetooth device blacklist.
devices
to blacklist all devices, other than those in the whitelist. The blacklist takes effect only after being activated using mdm_activate_bluetooth_device_restriction()
.[in] | devices | The Bluetooth devices to add to the blacklist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_add_bluetooth_devices_to_whitelist | ( | GList * | devices | ) |
API to add devices to the Bluetooth device whitelist.
devices
to add all devices to the whitelist. If a device is present in both the whitelist and blacklist, and was added by the same admin, then the whitelist takes precedence. The whitelist takes effect only after being activated using mdm_activate_bluetooth_device_restriction().[in] | devices | The Bluetooth devices to add to the whitelist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_add_bluetooth_uuids_to_blacklist | ( | GList * | uuids | ) |
API to add UUIDs to the Bluetooth UUID blacklist.
uuids
to blacklist all UUIDs, other than those in the whitelist. The blacklist is in effect only after being activated using mdm_activate_bluetooth_uuid_restriction().[in] | uuids | Bluetooth UUIDs to be added to blacklist |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_add_bluetooth_uuids_to_whitelist | ( | GList * | uuids | ) |
API to add UUIDs to the Bluetooth UUID whitelist.
uuids
to add all UUIDs to the whitelist. If one admin adds a UUID to both the whitelist and blacklist, the whitelist takes precedence. The whitelist takes effect only after being activated using mdm_activate_bluetooth_uuid_restriction()
.[in] | uuids | The Bluetooth UUIDs to add to the whitelist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_clear_bluetooth_devices_from_blacklist | ( | void | ) |
API to remove all devices from Bluetooth device blacklist.
mdm_activate_bluetooth_device_restriction()
.MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_clear_bluetooth_devices_from_whitelist | ( | void | ) |
API to clear all devices from the Bluetooth device whitelist.
mdm_activate_bluetooth_device_restriction()
.MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_clear_bluetooth_uuids_from_blacklist | ( | void | ) |
API to clear all UUIDs from Bluetooth UUID blacklist.
mdm_activate_bluetooth_uuid_restriction()
.MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_clear_bluetooth_uuids_from_whitelist | ( | void | ) |
API to clear all UUIDs from Bluetooth UUID whitelist.
mdm_activate_bluetooth_uuid_restriction()
.MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_bt_allow_t mdm_get_allow_bluetooth_mode | ( | void | ) |
API to check whether the mode of the Bluetooth capability is allowed, restricted, or set as "hands-free only".
MDM_BT_ERROR
on error.MDM_BT_ALLOWED | Bluetooth capability is allowed. |
MDM_BT_RESTRICTED | Bluetooth capability is restricted. |
MDM_BT_HANDSFREE_ONLY | Bluetooth capability is hands-free only. |
MDM_BT_ERROR | Encountered a Bluetooth allowance error. |
mdm_status_t mdm_get_allow_bluetooth_outgoing_call | ( | void | ) |
API to check whether outgoing calls are allowed via a Bluetooth headset.
MDM_ALLOWED | Allowed |
MDM_RESTRICTED | Eestricted |
mdm_data_t* mdm_get_bluetooth_bonded_device_list | ( | void | ) |
API to get a list of the bonded (paired) devices to the local adapter.
mdm_status_t mdm_get_bluetooth_data_transfer_state | ( | void | ) |
API to get whether data transfer via Bluetooth is allowed.
MDM_ALLOWED | Allowed |
MDM_RESTRICTED | Restricted |
mdm_data_t* mdm_get_bluetooth_devices_from_blacklist | ( | void | ) |
API to retrieve the list of blacklisted Bluetooth devices for all admins.
mdm_data_t* mdm_get_bluetooth_devices_from_whitelist | ( | void | ) |
API to retrieve the list of whitelisted Bluetooth devices for all admins.
mdm_status_t mdm_get_bluetooth_discoverable_state | ( | void | ) |
API to check whether discoverable mode is allowed.
MDM_ALLOWED | The mode is allowed |
MDM_RESTRICTED | Otherwise |
mdm_status_t mdm_get_bluetooth_pairing_state | ( | void | ) |
API to check whether Bluetooth pairing is allowed.
MDM_ALLOWED | Allowed |
MDM_RESTRICTED | Restricted |
mdm_status_t mdm_get_bluetooth_profile_state | ( | mdm_bt_profile_t | profile | ) |
API to check whether a specific Bluetooth profile is allowed.
[in] | profile | The Bluetooth profile to check the state of. |
MDM_ALLOWED | The profile is enabled. |
MDM_RESTRICTED | The profile is restricted. |
mdm_data_t* mdm_get_bluetooth_uuids_from_blacklist | ( | void | ) |
API to retrieve the list of blacklisted Bluetooth UUIDs for all admins.
mdm_data_t* mdm_get_bluetooth_uuids_from_whitelist | ( | void | ) |
API to retrieve the list of whitelisted Bluetooth UUIDs for all admins.
mdm_status_t mdm_is_bluetooth_device_restriction_active | ( | void | ) |
API to check if Bluetooth device restrictions are active.
mdm_status_t mdm_is_bluetooth_uuid_restriction_active | ( | void | ) |
API to check if Bluetooth UUID restrictions are active.
mdm_result_t mdm_remove_bluetooth_devices_from_blacklist | ( | GList * | devices | ) |
API to remove devices from the Bluetooth device blacklist.
[in] | devices | The Bluetooth devices to remove from the blacklist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_remove_bluetooth_devices_from_whitelist | ( | GList * | devices | ) |
API to remove devices from the Bluetooth device whitelist.
[in] | devices | The Bluetooth devices to remove from the whitelist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_remove_bluetooth_uuids_from_blacklist | ( | GList * | uuids | ) |
API to remove UUIDs from the Bluetooth UUID blacklist.
mdm_add_bluetooth_uuids_to_blacklist()
. Connections with matching UUID are allowed after this API call. The blacklist is in effect only after being activated using mdm_activate_bluetooth_uuid_restriction().[in] | uuids | Bluetooth UUIDs to remove from the blacklist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_remove_bluetooth_uuids_from_whitelist | ( | GList * | uuids | ) |
API to remove UUIDs from the Bluetooth UUID whitelist.
mdm_activate_bluetooth_uuid_restriction()
.[in] | uuids | The Bluetooth UUIDs to remove from the whitelist. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_set_allow_bluetooth_mode | ( | mdm_bt_allow_t | state | ) |
API to set the Bluetooth capability mode on the device.
[in] | state | The Bluetooth capability to set. Set to MDM_BT_ALLOWED to allow the usage of the Bluetooth capability on the device. Set to MDM_BT_HANDSFREE_ONLY to set the mode to "hands-free only". Set to MDM_BT_RESTRICTED to restrict the usage of the Bluetooth capability at all. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_set_allow_bluetooth_outgoing_call | ( | mdm_status_t | value | ) |
API to set whether to allow the transfer of outgoing calls to Bluetooth headsets.
The default setting allows outgoing calls.
[in] | value | Whether to allow the transfer of outgoing calls to Bluetooth headsets. Set to MDM_ALLOWED on allow transfer, or set to MDM_RESTRICTED to not allow transfers. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_set_bluetooth_data_transfer_state | ( | mdm_status_t | value | ) |
API to set whether to allow data transfer via Bluetooth.
[in] | value | Whether to allow Bluetooth data transfer. Set to MDM_ALLOWED to allow data transfer, or MDM_RESTRICTED to restrict it. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_set_bluetooth_discoverable_state | ( | mdm_status_t | value | ) |
API to set whether to allow Bluetooth discovery.
Bluetooth discoverable mode is allowed by default.
[in] | value | Whether to allow Bluetooth discovery. Set to MDM_ALLOWED to allow discoverable mode, or MDM_RESTRICTED to block it. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_set_bluetooth_pairing_state | ( | mdm_status_t | value | ) |
API to set whether to allow Bluetooth pairing with other Bluetooth devices.
[in] | value | Whether to allow Bluetooth pairing. Set to MDM_ALLOWED to allow pairing, or MDM_RESTRICTED to block it. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |
mdm_result_t mdm_set_bluetooth_profile_state | ( | mdm_status_t | state, |
mdm_bt_profile_t | profile | ||
) |
API to set the state of a Bluetooth profile.
The enum mdm_bt_profile_t
lists the available profiles.
BLUETOOTH_A2DP_PROFILE
):[in] | state | Whether to enable or disable the Bluetooth profile. Set to MDM_ALLOWED to enable the profile, or MDM_RESTRICTED to disable the profile. |
[in] | profile | The Bluetooth profile to set the state of. |
MDM_RESULT_SUCCESS | Successful |
MDM_RESULT_FAIL | General failure |
MDM_RESULT_NOT_SUPPORTED | Not supported |
MDM_RESULT_INVALID_PARAM | Invalid parameter |
MDM_RESULT_ACCESS_DENIED | The application does not have the privilege to call this function. |