MCPcopy
hub / github.com/Eugeny/tabby / readAll

Function readAll

tabby-core/src/api/platform.ts:101–113  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

99 abstract read (): Promise<Uint8Array>
100
101 async readAll (): Promise<Uint8Array> {
102 const result = new Uint8Array(this.getSize())
103 let pos = 0
104 while (true) {
105 const buf = await this.read()
106 if (!buf.length) {
107 break
108 }
109 result.set(buf, pos)
110 pos += buf.length
111 }
112 return result
113 }
114}
115
116export interface FileUploadOptions {

Callers

nothing calls this directly

Calls 3

setMethod · 0.80
getSizeMethod · 0.45
readMethod · 0.45

Tested by

no test coverage detected