Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions Bluetooth.Maui.Platforms.Droid/AndroidBluetoothAdapter.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using Bluetooth.Maui.Platforms.Droid.NativeObjects;
using Bluetooth.Maui.Platforms.Droid.Scanning;

namespace Bluetooth.Maui.Platforms.Droid;

Expand Down Expand Up @@ -48,4 +49,9 @@ private void OnBluetoothAdapterWrapperPropertyChanged(object? sender, PropertyCh
/// Gets the native Android Bluetooth manager.
/// </summary>
public BluetoothManager NativeBluetoothManager => BluetoothManagerWrapper.BluetoothManager;

/// <summary>
/// Gets the pairing manager used to bond with and unbond from remote devices.
/// </summary>
public AndroidBluetoothPairingManager PairingManager => field ??= new AndroidBluetoothPairingManager(this, Logger);
Comment on lines +53 to +56
}
Original file line number Diff line number Diff line change
Expand Up @@ -416,4 +416,19 @@ public static partial void LogL2CapReadLoopError(
Exception exception);

#endregion

#region Pairing Logging

[LoggerMessage(
EventId = 7012,
Level = LogLevel.Information,
Message = "Bond state of {Address}: {PreviousState} -> {State} (reason {Reason})")]
public static partial void LogBondStateChanged(
this ILogger logger,
string? address,
Bond previousState,
Bond state,
int reason);

#endregion
}
Loading
Loading