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

Method write

lib/internal/readline/interface.js:600–610  ·  view source on GitHub ↗

* Writes either `data` or a `key` sequence identified by * `key` to the `output`. * @param {string} d * @param {{ * ctrl?: boolean; * meta?: boolean; * shift?: boolean; * name?: string; * }} [key] * @returns {void}

(d, key)

Source from the content-addressed store, hash-verified

598 * @returns {void}
599 */
600 write(d, key) {
601 if (this.closed) {
602 throw new ERR_USE_AFTER_CLOSE('readline');
603 }
604 if (this.paused) this.resume();
605 if (this.terminal) {
606 this[kTtyWrite](d, key);
607 } else {
608 this[kNormalWrite](d);
609 }
610 }
611
612 [kNormalWrite](b) {
613 if (b === undefined) {

Callers 15

onDataFunction · 0.45
cursorToFunction · 0.45
moveCursorFunction · 0.45
clearLineFunction · 0.45
clearScreenDownFunction · 0.45
[kWriteToOutput]Method · 0.45
[kNormalWrite]Method · 0.45
cursorToMethod · 0.45
moveCursorMethod · 0.45
clearLineMethod · 0.45
clearScreenDownMethod · 0.45
commitMethod · 0.45

Calls 1

resumeMethod · 0.95

Tested by

no test coverage detected