共用方式為


JSRuntime.ReadJSDataAsStreamAsync 方法

定義

Stream提供 所 jsStreamReference 表示之資料參考的 。

protected internal virtual System.Threading.Tasks.Task<System.IO.Stream> ReadJSDataAsStreamAsync (Microsoft.JSInterop.IJSStreamReference jsStreamReference, long totalLength, System.Threading.CancellationToken cancellationToken = default);
abstract member ReadJSDataAsStreamAsync : Microsoft.JSInterop.IJSStreamReference * int64 * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.ReadJSDataAsStreamAsync : Microsoft.JSInterop.IJSStreamReference * int64 * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
Protected Friend Overridable Function ReadJSDataAsStreamAsync (jsStreamReference As IJSStreamReference, totalLength As Long, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Stream)

參數

jsStreamReference
IJSStreamReference

IJSStreamReference ,產生 的資料流程。

totalLength
Int64

傳入資料流程的預期長度。

cancellationToken
CancellationToken

CancellationToken 表示取消讀取。

傳回

Stream 表示的資料參考 jsStreamReference

適用於