Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1985)

Unified Diff: device/bluetooth/bluetooth_remote_gatt_service_chromeos.h

Issue 264053004: device/bluetooth: Improvements to GATT descriptor access API. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Pull & rebase. Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: device/bluetooth/bluetooth_remote_gatt_service_chromeos.h
diff --git a/device/bluetooth/bluetooth_remote_gatt_service_chromeos.h b/device/bluetooth/bluetooth_remote_gatt_service_chromeos.h
index b781ff2a85bb0a053b2e5dab90cf231fa5f5e775..f86c2ac6838f75ad6633d7d1dbacfec38f905f1d 100644
--- a/device/bluetooth/bluetooth_remote_gatt_service_chromeos.h
+++ b/device/bluetooth/bluetooth_remote_gatt_service_chromeos.h
@@ -27,6 +27,7 @@ namespace chromeos {
class BluetoothDeviceChromeOS;
class BluetoothRemoteGattCharacteristicChromeOS;
+class BluetoothRemoteGattDescriptorChromeOS;
// The BluetoothRemoteGattServiceChromeOS class implements BluetootGattService
// for remote GATT services on the the Chrome OS platform.
@@ -68,6 +69,25 @@ class BluetoothRemoteGattServiceChromeOS
// service observers when characteristic descriptors get added and removed.
void NotifyServiceChanged();
+ // Notifies its observers that a descriptor |descriptor| belonging to
+ // characteristic |characteristic| has been added or removed. This is used
+ // by BluetoothRemoteGattCharacteristicChromeOS instances to notify service
+ // observers when characteristic descriptors get added and removed. If |added|
+ // is true, an "Added" event will be sent. Otherwise, a "Removed" event will
+ // be sent.
+ void NotifyDescriptorAddedOrRemoved(
+ BluetoothRemoteGattCharacteristicChromeOS* characteristic,
+ BluetoothRemoteGattDescriptorChromeOS* descriptor,
+ bool added);
+
+ // Notifies its observers that the value of a descriptor has changed. Called
+ // by BluetoothRemoteGattCharacteristicChromeOS instances to notify service
+ // observers when the value of one of their descriptors gets updated.
+ void NotifyDescriptorValueChanged(
+ BluetoothRemoteGattCharacteristicChromeOS* characteristic,
+ BluetoothRemoteGattDescriptorChromeOS* descriptor,
+ const std::vector<uint8>& value);
+
private:
friend class BluetoothDeviceChromeOS;

Powered by Google App Engine
This is Rietveld 408576698