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 EXTENSIONS_BROWSER_API_BLUETOOTH_LOW_ENERGY_BLUETOOTH_LOW_ENERGY_EVENT_R
OUTER_H_ | 5 #ifndef EXTENSIONS_BROWSER_API_BLUETOOTH_LOW_ENERGY_BLUETOOTH_LOW_ENERGY_EVENT_R
OUTER_H_ |
6 #define EXTENSIONS_BROWSER_API_BLUETOOTH_LOW_ENERGY_BLUETOOTH_LOW_ENERGY_EVENT_R
OUTER_H_ | 6 #define EXTENSIONS_BROWSER_API_BLUETOOTH_LOW_ENERGY_BLUETOOTH_LOW_ENERGY_EVENT_R
OUTER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
313 const std::vector<uint8>& value); | 313 const std::vector<uint8>& value); |
314 | 314 |
315 // Called by BluetoothDevice in response to a call to CreateGattConnection. | 315 // Called by BluetoothDevice in response to a call to CreateGattConnection. |
316 void OnCreateGattConnection( | 316 void OnCreateGattConnection( |
317 bool persistent, | 317 bool persistent, |
318 const std::string& extension_id, | 318 const std::string& extension_id, |
319 const std::string& device_address, | 319 const std::string& device_address, |
320 const base::Closure& callback, | 320 const base::Closure& callback, |
321 scoped_ptr<device::BluetoothGattConnection> connection); | 321 scoped_ptr<device::BluetoothGattConnection> connection); |
322 | 322 |
323 // Called by BluetoothGattConnection in response to a call to Disconnect. | |
324 void OnDisconnect(const std::string& extension_id, | |
325 const std::string& device_address, | |
326 const base::Closure& callback); | |
327 | |
328 // Called by BluetoothGattCharacteristic and BluetoothGattDescriptor in | 323 // Called by BluetoothGattCharacteristic and BluetoothGattDescriptor in |
329 // case of an error during the read/write operations. | 324 // case of an error during the read/write operations. |
330 void OnError(const ErrorCallback& error_callback, | 325 void OnError(const ErrorCallback& error_callback, |
331 device::BluetoothGattService::GattErrorCode error_code); | 326 device::BluetoothGattService::GattErrorCode error_code); |
332 | 327 |
333 // Called by BluetoothDevice in response to a call to CreateGattConnection. | 328 // Called by BluetoothDevice in response to a call to CreateGattConnection. |
334 void OnConnectError(const std::string& extension_id, | 329 void OnConnectError(const std::string& extension_id, |
335 const std::string& device_address, | 330 const std::string& device_address, |
336 const ErrorCallback& error_callback, | 331 const ErrorCallback& error_callback, |
337 device::BluetoothDevice::ConnectErrorCode error_code); | 332 device::BluetoothDevice::ConnectErrorCode error_code); |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
421 // Note: This should remain the last member so it'll be destroyed and | 416 // Note: This should remain the last member so it'll be destroyed and |
422 // invalidate its weak pointers before any other members are destroyed. | 417 // invalidate its weak pointers before any other members are destroyed. |
423 base::WeakPtrFactory<BluetoothLowEnergyEventRouter> weak_ptr_factory_; | 418 base::WeakPtrFactory<BluetoothLowEnergyEventRouter> weak_ptr_factory_; |
424 | 419 |
425 DISALLOW_COPY_AND_ASSIGN(BluetoothLowEnergyEventRouter); | 420 DISALLOW_COPY_AND_ASSIGN(BluetoothLowEnergyEventRouter); |
426 }; | 421 }; |
427 | 422 |
428 } // namespace extensions | 423 } // namespace extensions |
429 | 424 |
430 #endif // EXTENSIONS_BROWSER_API_BLUETOOTH_LOW_ENERGY_BLUETOOTH_LOW_ENERGY_EVEN
T_ROUTER_H_ | 425 #endif // EXTENSIONS_BROWSER_API_BLUETOOTH_LOW_ENERGY_BLUETOOTH_LOW_ENERGY_EVEN
T_ROUTER_H_ |
OLD | NEW |