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

Unified Diff: device/bluetooth/bluetooth_adapter_win.h

Issue 1606013002: BLE GATT service implementation in Chrome for Windows 8 and later (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update Build.gn Created 4 years, 11 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_adapter_win.h
diff --git a/device/bluetooth/bluetooth_adapter_win.h b/device/bluetooth/bluetooth_adapter_win.h
index 936f420768407d1380f944060cee4b00cf9dd863..f1672112253e7b4743a5d3c911d1e1a10dc1fc43 100644
--- a/device/bluetooth/bluetooth_adapter_win.h
+++ b/device/bluetooth/bluetooth_adapter_win.h
@@ -32,8 +32,11 @@ class Thread;
namespace device {
class BluetoothAdapterWinTest;
-class BluetoothDevice;
+class BluetoothDeviceWin;
class BluetoothSocketThread;
+class BluetoothRemoteGattCharacteristicWin;
+class BluetoothRemoteGattDescriptorWin;
+class BluetoothRemoteGattServiceWin;
class DEVICE_BLUETOOTH_EXPORT BluetoothAdapterWin
: public BluetoothAdapter,
@@ -93,6 +96,34 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAdapterWin
return socket_thread_;
}
+ // The follwing methods are used to send various GATT observer events to
+ // observers.
+ void NotifyGattServiceAdded(BluetoothDeviceWin* device,
+ BluetoothRemoteGattServiceWin* service);
+ void NotifyGattServiceRemoved(BluetoothDeviceWin* device,
+ BluetoothRemoteGattServiceWin* service);
+ void NotifyGattServicesDiscovered(BluetoothDeviceWin* device);
+ void NotifyGattDiscoveryCompleteForService(
+ BluetoothRemoteGattServiceWin* service);
+ void NotifyGattServiceChanged(BluetoothRemoteGattServiceWin* service);
+ void NotifyGattCharacteristicAdded(
+ BluetoothRemoteGattCharacteristicWin* characteristic);
+ void NotifyGattCharacteristicRemoved(
+ BluetoothRemoteGattCharacteristicWin* characteristic);
+ void NotifyGattCharacteristicValueChanged(
+ BluetoothRemoteGattCharacteristicWin* characteristic,
+ const std::vector<uint8_t>& value);
+ void NotifyGattDescriptorAdded(BluetoothRemoteGattDescriptorWin* descriptor);
+ void NotifyGattDescriptorRemoved(
+ BluetoothRemoteGattDescriptorWin* descriptor);
+ void NotifyGattDescriptorValueChanged(
+ BluetoothRemoteGattDescriptorWin* descriptor,
+ const std::vector<uint8_t>& value);
+
+ BluetoothTaskManagerWin* GetWinBluetoothTaskManager() {
+ return task_manager_.get();
+ }
+
protected:
// BluetoothAdapter:
void RemovePairingDelegateInternal(
@@ -100,6 +131,9 @@ class DEVICE_BLUETOOTH_EXPORT BluetoothAdapterWin
private:
friend class BluetoothAdapterWinTest;
+ friend class BluetoothDeviceWinTest;
+ friend class BluetoothRemoteGattServiceWinTest;
+ friend class BluetoothRemoteGattCharacteristicWinTest;
enum DiscoveryStatus {
NOT_DISCOVERING,

Powered by Google App Engine
This is Rietveld 408576698