Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_CHROMEOS_BLUETOOTH_BLUETOOTH_ADAPTER_FACTORY_H_ | |
| 6 #define CHROME_BROWSER_CHROMEOS_BLUETOOTH_BLUETOOTH_ADAPTER_FACTORY_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "base/memory/ref_counted.h" | |
| 11 | |
| 12 namespace chromeos { | |
| 13 | |
| 14 class BluetoothAdapter; | |
| 15 | |
| 16 class BluetoothAdapterFactory { | |
|
keybuk
2012/09/17 22:19:43
Would a "Factory" be an appropriate class to add a
youngki
2012/09/18 18:19:56
Is that a new method that you want to add? I think
keybuk1
2012/09/18 18:42:30
yes, it's a method I have in a CL here that will b
youngki
2012/09/19 01:13:55
I think we could just leave the name "Factory" for
| |
| 17 public: | |
| 18 // Returns the shared instance for the default adapter, whichever that may | |
| 19 // be at the time. Use IsPresent() and the AdapterPresentChanged() observer | |
| 20 // method to determine whether an adapter is actually available or not. | |
| 21 static scoped_refptr<BluetoothAdapter> DefaultAdapter(); | |
| 22 | |
| 23 // Creates an instance for a specific adapter named by |address|, which | |
| 24 // may be the bluetooth address of the adapter or a device name such as | |
| 25 // "hci0". | |
|
keybuk
2012/09/17 22:19:43
I'm not sure what to do about the "device name" bi
youngki
2012/09/18 18:19:56
We could move this method to BluetoothAdapterChrom
keybuk1
2012/09/18 18:42:30
Actually I think we should just drop that from the
youngki
2012/09/19 01:13:55
Done.
| |
| 26 static BluetoothAdapter* Create(const std::string& address); | |
| 27 }; | |
| 28 | |
| 29 } // namespace chromeos | |
| 30 | |
| 31 #endif // CHROME_BROWSER_CHROMEOS_BLUETOOTH_BLUETOOTH_ADAPTER_FACTORY_H_ | |
| OLD | NEW |