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

Unified Diff: device/bluetooth/bluetooth_device_mac.h

Issue 12929003: Implemented BluetoothAdapterMac::AddDevices(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reverted BluetoothDevice interface. Created 7 years, 9 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_device_mac.h
diff --git a/device/bluetooth/bluetooth_device_mac.h b/device/bluetooth/bluetooth_device_mac.h
index 105de1ce0ea848de5f0aee93a080163618ec2043..d1f4b24fcadc55a4356285454c4c9449b5e8218a 100644
--- a/device/bluetooth/bluetooth_device_mac.h
+++ b/device/bluetooth/bluetooth_device_mac.h
@@ -10,11 +10,17 @@
#include "base/basictypes.h"
#include "device/bluetooth/bluetooth_device.h"
+#ifdef __OBJC__
+@class IOBluetoothDevice;
+#else
+class IOBluetoothDevice;
+#endif
+
namespace device {
class BluetoothDeviceMac : public BluetoothDevice {
public:
- BluetoothDeviceMac();
+ explicit BluetoothDeviceMac(const IOBluetoothDevice* device);
virtual ~BluetoothDeviceMac();
// BluetoothDevice override
@@ -54,6 +60,18 @@ class BluetoothDeviceMac : public BluetoothDevice {
const ErrorCallback& error_callback) OVERRIDE;
private:
+ friend class BluetoothAdapterMac;
+
+ // Computes the fingerprint that can be used to compare the devices.
+ static uint32 ComputeDeviceFingerprint(const IOBluetoothDevice* device);
+
+ uint32 device_fingerprint() const {
+ return device_fingerprint_;
+ }
+
+ // Used to compare the devices.
+ const uint32 device_fingerprint_;
+
DISALLOW_COPY_AND_ASSIGN(BluetoothDeviceMac);
};

Powered by Google App Engine
This is Rietveld 408576698