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

EventStream interface

可迭代和可释放的可读流。

扩展

ReadableStream<T>,AsyncIterable<T>

继承属性

locked

继承的方法

cancel(any)
getReader()
getReader(ReadableStreamGetReaderOptions)
getReader({ mode: "byob" })
pipeThrough<T>(ReadableWritablePair<T, T>, StreamPipeOptions)
pipeTo(WritableStream<T>, StreamPipeOptions)
tee()
[asyncIterator]()

继承属性详细信息

locked

locked: boolean

属性值

boolean

继承自 ReadableStream.locked

继承的方法详细信息

cancel(any)

function cancel(reason?: any): Promise<void>

参数

reason

any

返回

Promise<void>

继承自 ReadableStream.cancel

getReader()

function getReader(): ReadableStreamDefaultReader<T>

返回

ReadableStreamDefaultReader<T>

继承自 ReadableStream.getReader

getReader(ReadableStreamGetReaderOptions)

function getReader(options?: ReadableStreamGetReaderOptions): ReadableStreamReader<T>

参数

options

ReadableStreamGetReaderOptions

返回

ReadableStreamReader<T>

继承自 ReadableStream.getReader

getReader({ mode: "byob" })

function getReader(options: { mode: "byob" }): ReadableStreamBYOBReader

参数

options

{ mode: "byob" }

返回

ReadableStreamBYOBReader

继承自 ReadableStream.getReader

pipeThrough<T>(ReadableWritablePair<T, T>, StreamPipeOptions)

function pipeThrough<T>(transform: ReadableWritablePair<T, T>, options?: StreamPipeOptions): ReadableStream<T>

参数

transform

ReadableWritablePair<T, T>

options

StreamPipeOptions

返回

ReadableStream<T>

继承自 ReadableStream.pipeThrough

pipeTo(WritableStream<T>, StreamPipeOptions)

function pipeTo(destination: WritableStream<T>, options?: StreamPipeOptions): Promise<void>

参数

destination

WritableStream<T>

options

StreamPipeOptions

返回

Promise<void>

继承自 ReadableStream.pipeTo

tee()

function tee(): [ReadableStream<T>, ReadableStream<T>]

返回

[ReadableStream<T>, ReadableStream<T>]

继承自 ReadableStream.tee

[asyncIterator]()

function [asyncIterator](): AsyncIterator<T, any, undefined>

返回

AsyncIterator<T, any, undefined>

继承自 AsyncIterable.__@asyncIterator@374 的