Trait specs::prelude::RunNow

source ·
pub trait RunNow<'a> {
    fn run_now(&mut self, res: &'a Resources);
    fn setup(&mut self, res: &mut Resources);

    fn dispose(self: Box<Self, Global>, res: &mut Resources) { ... }
}
Expand description

Trait for fetching data and running systems. Automatically implemented for systems.

Required Methods

Runs the system now.

Panics

Panics if the system tries to fetch resources which are borrowed in an incompatible way already (tries to read from a resource which is already written to or tries to write to a resource which is read from).

Sets up Resources for a later call to run_now.

Provided Methods

Performs clean up that requires resources from the Resources.

This commonly removes components from Resources which depend on external resources.

Implementors