Expose LE advertiser address for easier PTS tests (3/6)

This patchset adds a hidden method getOwnAddress, that lets app with
BLUETOOTH_PRIVILEGED permission to lear their own addreess. This is done
exclusively for PTS tests.

Bug: 35147497
Test: manual
Change-Id: I39a6395d589d0ea801fd771bf3313ed6212a6349
(cherry picked from commit 788847a61a)
This commit is contained in:
Jakub Pawlowski 2017-04-19 07:03:14 -07:00
parent 1fb9687349
commit 43346aad01

View file

@ -57,6 +57,9 @@ class BleAdvertiserInterface {
/** Registers an advertiser with the stack */
virtual void RegisterAdvertiser(IdStatusCallback) = 0;
using GetAddressCallback = base::Callback<void(uint8_t /* address_type*/, bt_bdaddr_t /*address*/)>;
virtual void GetOwnAddress(uint8_t advertiser_id, GetAddressCallback cb) = 0;
/* Set the parameters as per spec, user manual specified values */
virtual void SetParameters(uint8_t advertiser_id, AdvertiseParameters params,
ParametersCallback cb) = 0;