| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_LOW_ENERGY_WIN_H_ | 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_LOW_ENERGY_WIN_H_ |
| 6 #define DEVICE_BLUETOOTH_BLUETOOTH_LOW_ENERGY_WIN_H_ | 6 #define DEVICE_BLUETOOTH_BLUETOOTH_LOW_ENERGY_WIN_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| 11 #include <memory> | 11 #include <memory> |
| 12 | 12 |
| 13 #include "base/files/file_path.h" | 13 #include "base/files/file_path.h" |
| 14 #include "base/macros.h" | 14 #include "base/macros.h" |
| 15 #include "base/memory/scoped_vector.h" | 15 #include "base/memory/scoped_vector.h" |
| 16 #include "base/optional.h" |
| 16 #include "device/bluetooth/bluetooth_export.h" | 17 #include "device/bluetooth/bluetooth_export.h" |
| 17 #include "device/bluetooth/bluetooth_low_energy_defs_win.h" | 18 #include "device/bluetooth/bluetooth_low_energy_defs_win.h" |
| 18 | 19 |
| 19 namespace device { | 20 namespace device { |
| 20 namespace win { | 21 namespace win { |
| 21 | 22 |
| 22 // Represents a device registry property value | 23 // Represents a device registry property value |
| 23 class DEVICE_BLUETOOTH_EXPORT DeviceRegistryPropertyValue { | 24 class DEVICE_BLUETOOTH_EXPORT DeviceRegistryPropertyValue { |
| 24 public: | 25 public: |
| 25 // Creates a property value instance, where |property_type| is one of REG_xxx | 26 // Creates a property value instance, where |property_type| is one of REG_xxx |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 // Attribute handle uniquely identifies this service on the device. | 82 // Attribute handle uniquely identifies this service on the device. |
| 82 USHORT attribute_handle = 0; | 83 USHORT attribute_handle = 0; |
| 83 }; | 84 }; |
| 84 | 85 |
| 85 struct DEVICE_BLUETOOTH_EXPORT BluetoothLowEnergyDeviceInfo { | 86 struct DEVICE_BLUETOOTH_EXPORT BluetoothLowEnergyDeviceInfo { |
| 86 BluetoothLowEnergyDeviceInfo(); | 87 BluetoothLowEnergyDeviceInfo(); |
| 87 ~BluetoothLowEnergyDeviceInfo(); | 88 ~BluetoothLowEnergyDeviceInfo(); |
| 88 | 89 |
| 89 base::FilePath path; | 90 base::FilePath path; |
| 90 std::string id; | 91 std::string id; |
| 91 std::string friendly_name; | 92 base::Optional<std::string> friendly_name; |
| 92 BLUETOOTH_ADDRESS address; | 93 BLUETOOTH_ADDRESS address; |
| 93 bool visible; | 94 bool visible; |
| 94 bool authenticated; | 95 bool authenticated; |
| 95 bool connected; | 96 bool connected; |
| 96 }; | 97 }; |
| 97 | 98 |
| 98 bool DEVICE_BLUETOOTH_EXPORT | 99 bool DEVICE_BLUETOOTH_EXPORT |
| 99 ExtractBluetoothAddressFromDeviceInstanceIdForTesting( | 100 ExtractBluetoothAddressFromDeviceInstanceIdForTesting( |
| 100 const std::string& instance_id, | 101 const std::string& instance_id, |
| 101 BLUETOOTH_ADDRESS* btha, | 102 BLUETOOTH_ADDRESS* btha, |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 196 | 197 |
| 197 protected: | 198 protected: |
| 198 BluetoothLowEnergyWrapper(); | 199 BluetoothLowEnergyWrapper(); |
| 199 virtual ~BluetoothLowEnergyWrapper(); | 200 virtual ~BluetoothLowEnergyWrapper(); |
| 200 }; | 201 }; |
| 201 | 202 |
| 202 } // namespace win | 203 } // namespace win |
| 203 } // namespace device | 204 } // namespace device |
| 204 | 205 |
| 205 #endif // DEVICE_BLUETOOTH_BLUETOOTH_LOW_ENERGY_WIN_H_ | 206 #endif // DEVICE_BLUETOOTH_BLUETOOTH_LOW_ENERGY_WIN_H_ |
| OLD | NEW |