Skip to main content

Observable

Trait Observable 

Source
pub trait Observable: Send + Sync {
    // Provided methods
    fn init(&self) -> Result<(), Error> { ... }
    fn serve<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait { ... }
    fn signal<'life0, 'life1, 'async_trait>(
        &'life0 self,
        _signal: &'life1 Signal,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait { ... }
}

Provided Methods§

Source

fn init(&self) -> Result<(), Error>

Source

fn serve<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn signal<'life0, 'life1, 'async_trait>( &'life0 self, _signal: &'life1 Signal, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§