GattDeviceService.Device 属性

定义

获取 BluetoothLEDevice 对象,该对象描述与当前 GattDeviceService 对象关联的设备。

重要

设备 API 已弃用,将来的 Windows 版本中可能不可用。 请改用 会话

public:
 property BluetoothLEDevice ^ Device { BluetoothLEDevice ^ get(); };
BluetoothLEDevice Device();
/// [get: Windows.Foundation.Metadata.Deprecated("Use Session instead of Device property.  For more information, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 262144, "Windows.Foundation.UniversalApiContract")]
BluetoothLEDevice Device();
public BluetoothLEDevice Device { get; }
public BluetoothLEDevice Device { [Windows.Foundation.Metadata.Deprecated("Use Session instead of Device property.  For more information, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 262144, "Windows.Foundation.UniversalApiContract")] get; }
var bluetoothLEDevice = gattDeviceService.device;
Public ReadOnly Property Device As BluetoothLEDevice

属性值

描述与当前 GattDeviceService 对象关联的设备的 BluetoothLEDevice 对象。

属性

Windows 要求

应用功能
bluetooth

适用于

另请参阅