BluetoothLEDevice.GetDeviceSelectorFromDeviceName(String) 方法

定义

(AQS) 筛选器字符串创建高级查询语法,其中包含蓝牙 LE 设备名称的查询。 AQS 字符串将传递到 CreateWatcher 方法,以返回包含指定蓝牙 LE 设备名称的 DeviceInformation 对象的集合。

public:
 static Platform::String ^ GetDeviceSelectorFromDeviceName(Platform::String ^ deviceName);
 static winrt::hstring GetDeviceSelectorFromDeviceName(winrt::hstring const& deviceName);
public static string GetDeviceSelectorFromDeviceName(string deviceName);
function getDeviceSelectorFromDeviceName(deviceName)
Public Shared Function GetDeviceSelectorFromDeviceName (deviceName As String) As String

参数

deviceName
String

Platform::String

winrt::hstring

用于构造 AQS 字符串的蓝牙 LE 设备名称。

返回

String

Platform::String

winrt::hstring

作为参数传递到 CreateWatcher 方法的 AQS 字符串。

Windows 要求

设备系列
Windows 10 (在 10.0.10586.0 - for Xbox, see UWP features that aren't yet supported on Xbox 中引入)
API contract
Windows.Foundation.UniversalApiContract (在 v2.0 中引入)
应用功能
bluetooth

适用于