Skip to main content

DriverLifecycle

Trait DriverLifecycle 

Source
pub trait DriverLifecycle {
    // Required methods
    fn drive(&mut self) -> Result<bool>;
    fn has_pending(&mut self) -> bool;
    fn park(&mut self) -> Result<()>;
    fn park_for(&mut self, duration: Duration) -> Result<()>;
    fn submit_only(&mut self) -> Result<()>;

    // Provided method
    fn arm_with_retry<F>(&mut self, op: F) -> bool
       where F: FnMut(&mut Self) -> bool { ... }
}

Required Methods§

Source

fn drive(&mut self) -> Result<bool>

Source

fn has_pending(&mut self) -> bool

Source

fn park(&mut self) -> Result<()>

Source

fn park_for(&mut self, duration: Duration) -> Result<()>

Source

fn submit_only(&mut self) -> Result<()>

Provided Methods§

Source

fn arm_with_retry<F>(&mut self, op: F) -> bool
where F: FnMut(&mut Self) -> bool,

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§