Skip to main content

Probe

Trait Probe 

Source
pub trait Probe {
    // Required methods
    fn output(&self, program: &str, args: &[&str]) -> Option<String>;
    fn exists(&self, path: &Path) -> bool;
    fn read(&self, path: &Path) -> Option<String>;
}
Expand description

How doctor looks at the machine.

Required Methods§

Source

fn output(&self, program: &str, args: &[&str]) -> Option<String>

What program with args prints on stdout, if it runs and succeeds.

Source

fn exists(&self, path: &Path) -> bool

Whether the file at path exists.

Source

fn read(&self, path: &Path) -> Option<String>

The text of the file at path, if it can be read.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§