Compartir a través de


CustomDevice.FromIdAsync(String, DeviceAccessMode, DeviceSharingMode) Método

Definición

Crea un objeto CustomDevice de forma asincrónica para el DeviceInformation.Id especificado.

public:
 static IAsyncOperation<CustomDevice ^> ^ FromIdAsync(Platform::String ^ deviceId, DeviceAccessMode desiredAccess, DeviceSharingMode sharingMode);
/// [Windows.Foundation.Metadata.RemoteAsync]
 static IAsyncOperation<CustomDevice> FromIdAsync(winrt::hstring const& deviceId, DeviceAccessMode const& desiredAccess, DeviceSharingMode const& sharingMode);
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<CustomDevice> FromIdAsync(string deviceId, DeviceAccessMode desiredAccess, DeviceSharingMode sharingMode);
function fromIdAsync(deviceId, desiredAccess, sharingMode)
Public Shared Function FromIdAsync (deviceId As String, desiredAccess As DeviceAccessMode, sharingMode As DeviceSharingMode) As IAsyncOperation(Of CustomDevice)

Parámetros

deviceId
String

Platform::String

winrt::hstring

El DeviceInformation.Id del dispositivo .

desiredAccess
DeviceAccessMode

Acceso deseado.

sharingMode
DeviceSharingMode

Modo de uso compartido.

Devoluciones

Devuelve un dispositivo personalizado.

Atributos

Requisitos de Windows

Características de aplicaciones
optical iot:lowLevelDevices

Se aplica a