MCPcopy
hub / github.com/callstack/agent-device / push

Method push

src/mcp/server.ts:135–145  ·  view source on GitHub ↗
(chunk: string)

Source from the content-addressed store, hash-verified

133 }
134
135 push(chunk: string): void {
136 this.buffer += chunk;
137 for (;;) {
138 const line = this.tryReadLineMessage();
139 if (line !== undefined) {
140 this.emit(line);
141 continue;
142 }
143 break;
144 }
145 }
146
147 private tryReadLineMessage(): string | undefined {
148 const newline = this.buffer.indexOf('\n');

Callers 15

runAgentDeviceMcpServerFunction · 0.95
readJsonBodyFunction · 0.80
readJsonBodyFunction · 0.80
recordStepFunction · 0.80
buildFailureDebugFunction · 0.80
cleanupWebSmokeFunction · 0.80
recordStepFunction · 0.80
buildFailureDebugFunction · 0.80
acceptMethod · 0.80
updateMethod · 0.80

Calls 2

tryReadLineMessageMethod · 0.95
emitMethod · 0.95

Tested by 15

readJsonBodyFunction · 0.64
readJsonBodyFunction · 0.64
cleanupWebSmokeFunction · 0.64
recordStepFunction · 0.64
buildFailureDebugFunction · 0.64
acceptMethod · 0.64
updateMethod · 0.64
readJsonBodyFunction · 0.64