Skip to main content

define_update_engine

Macro define_update_engine 

Source
macro_rules! define_update_engine {
    ($v:vis $spec_type:ty) => { ... };
}
Expand description

Defines type aliases for engine-crate types parameterized by a particular EngineSpec.

This macro defines a number of type aliases. For example:

oxide_update_engine::define_update_engine!(pub(crate) MySpec);

defines a number of type aliases, each of which are of the form:

pub(crate) type UpdateEngine<'a, S = MySpec> =
    oxide_update_engine::UpdateEngine<'a, S>;
pub(crate) type StepContext<S = MySpec> =
    oxide_update_engine::StepContext<S>;
// ... and so on.

For types-crate aliases (events, buffers, etc.), use the companion macro oxide_update_engine_types::define_update_engine_types!.