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

FileUploadNotificationProcessorClient.FileUploadNotificationProcessor 属性

定义

每次从服务接收文件上传通知时要执行的回调。

public Func<Microsoft.Azure.Devices.FileUploadNotification,Microsoft.Azure.Devices.AcknowledgementType> FileUploadNotificationProcessor { get; set; }
member this.FileUploadNotificationProcessor : Func<Microsoft.Azure.Devices.FileUploadNotification, Microsoft.Azure.Devices.AcknowledgementType> with get, set
Public Property FileUploadNotificationProcessor As Func(Of FileUploadNotification, AcknowledgementType)

属性值

示例

serviceClient.FileUploadNotificationProcessor.FileUploadNotificationProcessor = OnFileUploadNotificationReceived;serviceClient.FileUploadNotificationProcessor.OpenAsync () ;

//...

public AcknowledgementType OnFileUploadNotificationReceived (FileUploadNotification fileUploadNotification) { Console.WriteLine ($“收到的文件上传通知从设备 {fileUploadNotification.DeviceId}”) 返回 AcknowledgementType.Complete; }

注解

不能为 null。

适用于