MCPcopy Create free account
hub / github.com/MCSManager/MCSManager / flushOutputBuffer

Method flushOutputBuffer

daemon/src/entity/instance/instance.ts:590–596  ·  view source on GitHub ↗
(shouldClear = false)

Source from the content-addressed store, hash-verified

588 }
589
590 private flushOutputBuffer(shouldClear = false) {
591 const { items, wasDeleted } = this.outputBuffer.getCache();
592 if (!items.length) return;
593 if (wasDeleted) items.unshift(IGNORE_TEXT);
594 if (shouldClear) this.outputBuffer.clear();
595 this.emit("data", items.join(""));
596 }
597
598 private startOutputLoop() {
599 this.outputBuffer = new CircularBuffer<string>(

Callers 2

startOutputLoopMethod · 0.95
stopOutputLoopMethod · 0.95

Calls 3

getCacheMethod · 0.80
emitMethod · 0.80
clearMethod · 0.45

Tested by

no test coverage detected