The interface contains mix-in utility functions to transfer the runtime-specific stream implementation to specified format. Each stream can ONLY be transformed once.

interface SdkStreamMixin {
    transformToByteArray: (() => Promise<Uint8Array<ArrayBufferLike>>);
    transformToString: ((encoding?) => Promise<string>);
    transformToWebStream: (() => ReadableStream<any>);
}

Properties

transformToByteArray: (() => Promise<Uint8Array<ArrayBufferLike>>)

Type declaration

transformToString: ((encoding?) => Promise<string>)

Type declaration

    • (encoding?): Promise<string>
    • Parameters

      • Optional encoding: string

      Returns Promise<string>

transformToWebStream: (() => ReadableStream<any>)

Type declaration

    • (): ReadableStream<any>
    • Returns ReadableStream<any>