你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

RegistryManager.AddDeviceWithTwinAsync 方法

定义

重载

AddDeviceWithTwinAsync(Device, Twin)

添加包含孪生信息的设备

AddDeviceWithTwinAsync(Device, Twin, CancellationToken)

添加包含孪生信息的设备

AddDeviceWithTwinAsync(Device, Twin)

添加包含孪生信息的设备

public virtual System.Threading.Tasks.Task<Microsoft.Azure.Devices.BulkRegistryOperationResult> AddDeviceWithTwinAsync (Microsoft.Azure.Devices.Device device, Microsoft.Azure.Devices.Shared.Twin twin);
abstract member AddDeviceWithTwinAsync : Microsoft.Azure.Devices.Device * Microsoft.Azure.Devices.Shared.Twin -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.BulkRegistryOperationResult>
override this.AddDeviceWithTwinAsync : Microsoft.Azure.Devices.Device * Microsoft.Azure.Devices.Shared.Twin -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.BulkRegistryOperationResult>
Public Overridable Function AddDeviceWithTwinAsync (device As Device, twin As Twin) As Task(Of BulkRegistryOperationResult)

参数

device
Device

要添加的设备。

twin
Twin

要添加的设备的孪生信息。

返回

添加操作的结果。

适用于

AddDeviceWithTwinAsync(Device, Twin, CancellationToken)

添加包含孪生信息的设备

public virtual System.Threading.Tasks.Task<Microsoft.Azure.Devices.BulkRegistryOperationResult> AddDeviceWithTwinAsync (Microsoft.Azure.Devices.Device device, Microsoft.Azure.Devices.Shared.Twin twin, System.Threading.CancellationToken cancellationToken);
abstract member AddDeviceWithTwinAsync : Microsoft.Azure.Devices.Device * Microsoft.Azure.Devices.Shared.Twin * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.BulkRegistryOperationResult>
override this.AddDeviceWithTwinAsync : Microsoft.Azure.Devices.Device * Microsoft.Azure.Devices.Shared.Twin * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Azure.Devices.BulkRegistryOperationResult>
Public Overridable Function AddDeviceWithTwinAsync (device As Device, twin As Twin, cancellationToken As CancellationToken) As Task(Of BulkRegistryOperationResult)

参数

device
Device

要添加的设备。

twin
Twin

要添加的设备的孪生信息。

cancellationToken
CancellationToken

用于取消操作的取消标记。

返回

添加操作的结果。

适用于