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

CallingServerClient.DownloadToAsync 方法

定义

重载

DownloadToAsync(Uri, Stream, ContentTransferOptions, CancellationToken)

操作 DownloadToAsync(Uri, Stream, ContentTransferOptions, CancellationToken) 使用并行请求下载指定内容,并将内容写入 destinationStream

DownloadToAsync(Uri, String, ContentTransferOptions, CancellationToken)

操作 DownloadToAsync(Uri, String, ContentTransferOptions, CancellationToken) 使用并行请求下载指定内容,并将内容写入 destinationPath

DownloadToAsync(Uri, Stream, ContentTransferOptions, CancellationToken)

Source:
CallingServerClient.cs

操作 DownloadToAsync(Uri, Stream, ContentTransferOptions, CancellationToken) 使用并行请求下载指定内容,并将内容写入 destinationStream

public virtual System.Threading.Tasks.Task<Azure.Response> DownloadToAsync (Uri sourceEndpoint, System.IO.Stream destinationStream, Azure.Communication.CallingServer.ContentTransferOptions transferOptions = default, System.Threading.CancellationToken cancellationToken = default);
abstract member DownloadToAsync : Uri * System.IO.Stream * Azure.Communication.CallingServer.ContentTransferOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
override this.DownloadToAsync : Uri * System.IO.Stream * Azure.Communication.CallingServer.ContentTransferOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function DownloadToAsync (sourceEndpoint As Uri, destinationStream As Stream, Optional transferOptions As ContentTransferOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response)

参数

sourceEndpoint
Uri

具有 Uri 录制内容的 URL 位置的 。

destinationStream
Stream

Stream 向其写入下载内容的 。

transferOptions
ContentTransferOptions

可选 ContentTransferOptions ,用于配置并行传输行为。

cancellationToken
CancellationToken

可选 CancellationToken ,用于传播应取消操作的通知。

返回

描述 Response 操作的 。

注解

RequestFailedException如果失败,将引发 。

适用于

DownloadToAsync(Uri, String, ContentTransferOptions, CancellationToken)

Source:
CallingServerClient.cs

操作 DownloadToAsync(Uri, String, ContentTransferOptions, CancellationToken) 使用并行请求下载指定内容,并将内容写入 destinationPath

public virtual System.Threading.Tasks.Task<Azure.Response> DownloadToAsync (Uri sourceEndpoint, string destinationPath, Azure.Communication.CallingServer.ContentTransferOptions transferOptions = default, System.Threading.CancellationToken cancellationToken = default);
abstract member DownloadToAsync : Uri * string * Azure.Communication.CallingServer.ContentTransferOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
override this.DownloadToAsync : Uri * string * Azure.Communication.CallingServer.ContentTransferOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function DownloadToAsync (sourceEndpoint As Uri, destinationPath As String, Optional transferOptions As ContentTransferOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response)

参数

sourceEndpoint
Uri

具有 Uri 录制内容的 URL 位置的 。

destinationPath
String

要向其写入下载内容的文件路径。

transferOptions
ContentTransferOptions

可选 ContentTransferOptions ,用于配置并行传输行为。

cancellationToken
CancellationToken

可选 CancellationToken ,用于传播应取消操作的通知。

返回

描述 Response 操作的 。

注解

RequestFailedException如果失败,将引发 。

适用于