mirror of
https://github.com/kidfromjupiter/nearby.git
synced 2026-09-16 15:36:12 -04:00
BluetoothClassicMedium::GetRemoteDevice and BluetoothClassicSocket::Close implmentations
PiperOrigin-RevId: 390691122
This commit is contained in:
committed by
Copybara-Service
parent
628255ac59
commit
913a639a5d
@@ -44,11 +44,6 @@ BluetoothClassicMedium::BluetoothClassicMedium() {
|
||||
|
||||
BluetoothClassicMedium::~BluetoothClassicMedium() {}
|
||||
|
||||
// TODO(b/184975123): replace with real implementation.
|
||||
api::BluetoothDevice* GetRemoteDevice(const std::string& mac_address) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
bool BluetoothClassicMedium::StartDiscovery(
|
||||
BluetoothClassicMedium::DiscoveryCallback discovery_callback) {
|
||||
EnterCriticalSection(&critical_section_);
|
||||
@@ -148,7 +143,7 @@ std::unique_ptr<api::BluetoothSocket> BluetoothClassicMedium::ConnectToService(
|
||||
EnterCriticalSection(&critical_section_);
|
||||
|
||||
std::unique_ptr<BluetoothSocket> rfcommSocket =
|
||||
std::make_unique<BluetoothSocket>();
|
||||
std::make_unique<BluetoothSocket>(nullptr);
|
||||
|
||||
location::nearby::CancellationFlagListener cancellationFlagListener(
|
||||
cancellation_flag,
|
||||
@@ -263,10 +258,9 @@ BluetoothClassicMedium::ListenForService(const std::string& service_name,
|
||||
return std::move(bluetooth_server_socket);
|
||||
}
|
||||
|
||||
// TODO(b/184975123): replace with real implementation.
|
||||
api::BluetoothDevice* BluetoothClassicMedium::GetRemoteDevice(
|
||||
const std::string& mac_address) {
|
||||
return nullptr;
|
||||
return new BluetoothDevice(mac_address);
|
||||
}
|
||||
|
||||
bool BluetoothClassicMedium::StartScanning() {
|
||||
|
||||
Reference in New Issue
Block a user