(chunks: Uint8Array[], totalLength: number)
| 405 | } |
| 406 | |
| 407 | private concatChunks(chunks: Uint8Array[], totalLength: number): Uint8Array<ArrayBuffer> { |
| 408 | const chunksAll = new Uint8Array(totalLength); |
| 409 | let position = 0; |
| 410 | for (const chunk of chunks) { |
| 411 | chunksAll.set(chunk, position); |
| 412 | position += chunk.length; |
| 413 | } |
| 414 | |
| 415 | return chunksAll; |
| 416 | } |
| 417 | } |
| 418 | |
| 419 | /** |