The source of response chunks. A platform provides the iterator from its own stream type. For example, a Node IncomingMessage provides a compatible iterator through its Symbol.asyncIterator method.

Hierarchy

  • ResponseChunkIterator

Methods

Methods

  • Resolves with the next chunk, or with done: true when the stream ends. Rejects when the connection terminates before the server ends the stream. A chunk delivered together with done: true is discarded, so the iterator must deliver the last chunk on its own.

    Returns Promise<{
        done?: boolean;
        value?: Uint8Array;
    }>

  • Releases the iterator. A Node Readable iterator queues this call behind a pending read, so this call alone does not release an idle stream.

    Returns Promise<{
        done?: boolean;
        value?: Uint8Array;
    }>

Generated using TypeDoc