MCPcopy Create free account
hub / github.com/Henktorius/float / process

Method process

src/pty.rs:79–91  ·  view source on GitHub ↗

Drain all buffered PTY output into the vt100 parser. Returns true if any data was consumed.

(&mut self)

Source from the content-addressed store, hash-verified

77 /// Drain all buffered PTY output into the vt100 parser.
78 /// Returns true if any data was consumed.
79 pub fn process(&mut self) -> bool {
80 let mut got = false;
81 while let Ok(bytes) = self.rx.try_recv() {
82 let fixed = fix_escape_sequences(&bytes);
83
84 // Feed to parser first so screen state is current when we
85 // respond to any terminal queries embedded in the output.
86 self.parser.process(&fixed);
87 respond_to_queries(&mut self.writer, &fixed, self.parser.screen());
88 got = true;
89 }
90 got
91 }
92
93 /// Returns the child process command name from /proc/<pid>/comm, if available.
94 pub fn process_name(&self) -> Option<String> {

Callers 1

process_allMethod · 0.45

Calls 3

fix_escape_sequencesFunction · 0.85
respond_to_queriesFunction · 0.85
screenMethod · 0.45

Tested by

no test coverage detected