pub enum ProcessEvent {
Stdout(String),
Stderr(String),
StdoutPartial(String),
StderrPartial(String),
Exited(i32),
Signaled(i32),
Killed,
Error(String),
}Expand description
Events emitted by a ProcessSubscription.
Variants§
Stdout(String)
A UTF-8 stdout line, without LF or CRLF, up to MAX_PROCESS_LINE_BYTES.
Stderr(String)
A UTF-8 stderr line, without LF or CRLF, up to MAX_PROCESS_LINE_BYTES.
StdoutPartial(String)
Cumulative valid UTF-8 prefix of the pending stdout line.
Emitted only with ProcessSubscription::partial_output. Replace the
previous preview; do not append it or count it as a completed line.
The original controls are retained for whole-prefix sanitization.
StderrPartial(String)
Cumulative pending stderr prefix, with the same contract as
Self::StdoutPartial.
Exited(i32)
The process exited with a status code.
Signaled(i32)
The process was terminated by a Unix signal.
Killed
Termination was requested and the immediate child was reaped.
On Unix its observed status must be SIGKILL. Pending input/output may
be incomplete. Failed or unconfirmed cleanup produces Self::Error.
Error(String)
Spawning, monitoring, or process pipe I/O failed.