JobSet

Trait JobSet 

Source
pub trait JobSet {
    // Required methods
    fn reload_unit(&mut self, unit_name: &str) -> Result<(), Error>;
    fn restart_unit(&mut self, unit_name: &str) -> Result<(), Error>;
    fn start_unit(&mut self, unit_name: &str) -> Result<(), Error>;
    fn stop_unit(&mut self, unit_name: &str) -> Result<(), Error>;
    fn wait_for_all<F>(
        &mut self,
        job_handler: F,
        timeout: Duration,
    ) -> Result<(), Error>
       where F: Fn(&str, &str) + Send + 'static;
}

Required Methods§

Source

fn reload_unit(&mut self, unit_name: &str) -> Result<(), Error>

Source

fn restart_unit(&mut self, unit_name: &str) -> Result<(), Error>

Source

fn start_unit(&mut self, unit_name: &str) -> Result<(), Error>

Source

fn stop_unit(&mut self, unit_name: &str) -> Result<(), Error>

Source

fn wait_for_all<F>( &mut self, job_handler: F, timeout: Duration, ) -> Result<(), Error>
where F: Fn(&str, &str) + Send + 'static,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§