OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_DEVICE_MAC_H_ | 5 #ifndef DEVICE_BLUETOOTH_BLUETOOTH_DEVICE_MAC_H_ |
6 #define DEVICE_BLUETOOTH_BLUETOOTH_DEVICE_MAC_H_ | 6 #define DEVICE_BLUETOOTH_BLUETOOTH_DEVICE_MAC_H_ |
7 | 7 |
8 #import <IOBluetooth/IOBluetooth.h> | 8 #import <IOBluetooth/IOBluetooth.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 const BluetoothUUID& uuid, | 66 const BluetoothUUID& uuid, |
67 const ConnectToServiceCallback& callback, | 67 const ConnectToServiceCallback& callback, |
68 const ConnectToServiceErrorCallback& error_callback) OVERRIDE; | 68 const ConnectToServiceErrorCallback& error_callback) OVERRIDE; |
69 virtual void SetOutOfBandPairingData( | 69 virtual void SetOutOfBandPairingData( |
70 const BluetoothOutOfBandPairingData& data, | 70 const BluetoothOutOfBandPairingData& data, |
71 const base::Closure& callback, | 71 const base::Closure& callback, |
72 const ErrorCallback& error_callback) OVERRIDE; | 72 const ErrorCallback& error_callback) OVERRIDE; |
73 virtual void ClearOutOfBandPairingData( | 73 virtual void ClearOutOfBandPairingData( |
74 const base::Closure& callback, | 74 const base::Closure& callback, |
75 const ErrorCallback& error_callback) OVERRIDE; | 75 const ErrorCallback& error_callback) OVERRIDE; |
| 76 virtual void StartConnectionMonitor( |
| 77 const base::Closure& callback, |
| 78 const ErrorCallback& error_callback) OVERRIDE; |
| 79 virtual void StopConnectionMonitor( |
| 80 const base::Closure& callback, |
| 81 const ErrorCallback& error_callback) OVERRIDE; |
76 | 82 |
77 // Returns the Bluetooth address for the |device|. The returned address has a | 83 // Returns the Bluetooth address for the |device|. The returned address has a |
78 // normalized format (see below). | 84 // normalized format (see below). |
79 static std::string GetDeviceAddress(IOBluetoothDevice* device); | 85 static std::string GetDeviceAddress(IOBluetoothDevice* device); |
80 | 86 |
81 // Returns the address formatted according to Chrome's expectations rather | 87 // Returns the address formatted according to Chrome's expectations rather |
82 // than per the system convention: octets are separated by colons rather than | 88 // than per the system convention: octets are separated by colons rather than |
83 // by dashes. That is, the returned format is XX:XX:XX:XX:XX:XX rather than | 89 // by dashes. That is, the returned format is XX:XX:XX:XX:XX:XX rather than |
84 // xx-xx-xx-xx-xx-xx. | 90 // xx-xx-xx-xx-xx-xx. |
85 static std::string NormalizeAddress(const std::string& address); | 91 static std::string NormalizeAddress(const std::string& address); |
(...skipping 14 matching lines...) Expand all Loading... |
100 ObserverList<Observer> observers_; | 106 ObserverList<Observer> observers_; |
101 | 107 |
102 base::scoped_nsobject<IOBluetoothDevice> device_; | 108 base::scoped_nsobject<IOBluetoothDevice> device_; |
103 | 109 |
104 DISALLOW_COPY_AND_ASSIGN(BluetoothDeviceMac); | 110 DISALLOW_COPY_AND_ASSIGN(BluetoothDeviceMac); |
105 }; | 111 }; |
106 | 112 |
107 } // namespace device | 113 } // namespace device |
108 | 114 |
109 #endif // DEVICE_BLUETOOTH_BLUETOOTH_DEVICE_MAC_H_ | 115 #endif // DEVICE_BLUETOOTH_BLUETOOTH_DEVICE_MAC_H_ |
OLD | NEW |