pub trait Provider {
    // Required method
    fn provide<'a>(&'a self, demand: &mut Demand<'a>);

    // Provided method
    fn provide_mut<'a>(&'a mut self, _demand: &mut Demand<'a>) { ... }
}
Expand description

An object of arbitrary type. This whole API is stolen from Rust’s std::any::Provider. We should remove this when that stabilizes.

Required Methods§

source

fn provide<'a>(&'a self, demand: &mut Demand<'a>)

Provided Methods§

source

fn provide_mut<'a>(&'a mut self, _demand: &mut Demand<'a>)

Implementations on Foreign Types§

source§

impl Provider for ()

source§

fn provide<'a>(&'a self, demand: &mut Demand<'a>)

source§

fn provide_mut<'a>(&'a mut self, demand: &mut Demand<'a>)

Implementors§