pub struct EnginePlugin { /* private fields */ }Expand description
A plugin that injects callbacks into the frame pipeline.
Implementations§
Source§impl EnginePlugin
impl EnginePlugin
Sourcepub fn on_phase(
&mut self,
phase: ExecutionPhase,
f: impl Fn(&mut World) + Send + 'static,
)
pub fn on_phase( &mut self, phase: ExecutionPhase, f: impl Fn(&mut World) + Send + 'static, )
Registers a callback for a specific execution phase.
Sourcepub fn execute(&mut self, phase: ExecutionPhase, world: &mut World)
pub fn execute(&mut self, phase: ExecutionPhase, world: &mut World)
Executes the hook for a phase, if one is registered.
Sourcepub fn wants_phase(&self, phase: ExecutionPhase) -> bool
pub fn wants_phase(&self, phase: ExecutionPhase) -> bool
Returns true if this plugin has a hook for the given phase.
Auto Trait Implementations§
impl Freeze for EnginePlugin
impl !RefUnwindSafe for EnginePlugin
impl Send for EnginePlugin
impl !Sync for EnginePlugin
impl Unpin for EnginePlugin
impl UnsafeUnpin for EnginePlugin
impl !UnwindSafe for EnginePlugin
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more