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

Function pull

benchmark/streams/iter-throughput-compression.js:60–66  ·  view source on GitHub ↗
(controller)

Source from the content-addressed store, hash-verified

58 let remaining = datasize;
59 const rs = new ReadableStream({
60 pull(controller) {
61 if (remaining <= 0) { controller.close(); return; }
62 const size = Math.min(remaining, chunk.length);
63 remaining -= size;
64 controller.enqueue(
65 size === chunk.length ? chunk : chunk.subarray(0, size));
66 },
67 });
68 const ws = new WritableStream({ write() {} });
69 await rs

Callers

nothing calls this directly

Calls 3

closeMethod · 0.65
minMethod · 0.45
enqueueMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…