MCPcopy Index your code
hub / github.com/nodejs/node / read

Function read

benchmark/streams/iter-throughput-pipeto.js:40–45  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

38 let remaining = datasize;
39 const r = new Readable({
40 read() {
41 if (remaining <= 0) { this.push(null); return; }
42 const size = Math.min(remaining, chunk.length);
43 remaining -= size;
44 this.push(size === chunk.length ? chunk : chunk.subarray(0, size));
45 },
46 });
47 const w = new Writable({ write(data, enc, cb) { cb(); } });
48 pipeline(r, w, cb);

Callers

nothing calls this directly

Calls 2

pushMethod · 0.45
minMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…