NotificationMessagesClient.DownloadMediaToAsync Method

Definition

Overloads

DownloadMediaToAsync(String, Stream, CancellationToken)

The DownloadMediaToAsync(String, Stream, CancellationToken) operation downloads the specified content asynchronously, and writes the content to destinationStream.

DownloadMediaToAsync(String, String, CancellationToken)

The DownloadMediaTo(String, String, CancellationToken) operation downloads the specified content, and writes the content to destinationPath.

DownloadMediaToAsync(String, Stream, CancellationToken)

Source:
NotificationMessagesClient.cs
Source:
NotificationMessagesClient.cs

The DownloadMediaToAsync(String, Stream, CancellationToken) operation downloads the specified content asynchronously, and writes the content to destinationStream.

public virtual System.Threading.Tasks.Task<Azure.Response> DownloadMediaToAsync (string mediaContentId, System.IO.Stream destinationStream, System.Threading.CancellationToken cancellationToken = default);
abstract member DownloadMediaToAsync : string * System.IO.Stream * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
override this.DownloadMediaToAsync : string * System.IO.Stream * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function DownloadMediaToAsync (mediaContentId As String, destinationStream As Stream, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response)

Parameters

mediaContentId
String

The Media Identifier contained in the User to Business message event.

destinationStream
Stream

A Stream to write the downloaded content to.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

The server returned an error. See Message for details returned from the server.

Applies to

DownloadMediaToAsync(String, String, CancellationToken)

Source:
NotificationMessagesClient.cs
Source:
NotificationMessagesClient.cs

The DownloadMediaTo(String, String, CancellationToken) operation downloads the specified content, and writes the content to destinationPath.

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

Parameters

mediaContentId
String

The Media Identifier contained in the User to Business message event.

destinationPath
String

A file path to write the downloaded content to.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

The server returned an error. See Message for details returned from the server.

Applies to