Skip to main content

Drain

Trait Drain 

Source
pub unsafe trait Drain<'d>: App<'d> {
    // Required methods
    fn begin(
        self: Pin<&mut Self>,
        turn: Turn<'_, 'd>,
        driver: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
    );
    fn progress(
        self: Pin<&Self>,
        region: &Token<Identity<'d>>,
        state: Option<&mut Waits<'d>>,
    ) -> ControlFlow<()>;
    fn force(
        self: Pin<&mut Self>,
        turn: Turn<'_, 'd>,
        driver: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>,
    );
}
Expand description

§Safety

Keep admitted owner identities, presence, addresses and routes fixed through finish. Neither method replaces owners or reclaims storage before native shutdown and drain.

Required Methods§

Source

fn begin( self: Pin<&mut Self>, turn: Turn<'_, 'd>, driver: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>, )

Source

fn progress( self: Pin<&Self>, region: &Token<Identity<'d>>, state: Option<&mut Waits<'d>>, ) -> ControlFlow<()>

Reports drain work after the application’s pre-park traversal. Completion does not authorize reclaiming retained native owners.

Source

fn force( self: Pin<&mut Self>, turn: Turn<'_, 'd>, driver: &mut Lifecycle<'d, impl Report<Event = <Arena as Drain>::Reported>>, )

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§

Source§

impl<'d, H, T> Drain<'d> for Bound<'_, 'd, H, T>
where Self: App<'d>, T: Drain<'d>,