pub trait OutputLike {
    // Required methods
    fn status(&self) -> ExitStatus;
    fn stdout(&self) -> Cow<'_, str>;
    fn stderr(&self) -> Cow<'_, str>;
}
Expand description

A command output type.

Required Methods§

source

fn status(&self) -> ExitStatus

The command’s exit status.

source

fn stdout(&self) -> Cow<'_, str>

The command’s stdout, decoded to UTF-8 on a best-effort basis.

source

fn stderr(&self) -> Cow<'_, str>

The command’s stderr, decoded to UTF-8 on a best-effort basis.

Implementations on Foreign Types§

source§

impl OutputLike for ExitStatus

A trivial implementation with empty output.

source§

fn status(&self) -> ExitStatus

source§

fn stdout(&self) -> Cow<'_, str>

source§

fn stderr(&self) -> Cow<'_, str>

source§

impl OutputLike for Output

source§

fn status(&self) -> ExitStatus

source§

fn stdout(&self) -> Cow<'_, str>

source§

fn stderr(&self) -> Cow<'_, str>

source§

impl OutputLike for Utf8Output

source§

fn status(&self) -> ExitStatus

source§

fn stdout(&self) -> Cow<'_, str>

source§

fn stderr(&self) -> Cow<'_, str>

Implementors§