pub trait ShellRuntime {
type LoopHandle;
type Context<'a>;
// Required methods
fn event_loop_handle(&self) -> Self::LoopHandle;
fn with_component<F>(&self, name: &str, f: F)
where F: FnMut(&ComponentInstance);
fn with_all_components<F>(&self, f: F)
where F: FnMut(&str, &ComponentInstance);
fn run(&mut self) -> Result<(), Error>;
}Expand description
Trait providing runtime access to shell components and event loop
Required Associated Types§
type LoopHandle
type Context<'a>
Required Methods§
fn event_loop_handle(&self) -> Self::LoopHandle
fn with_component<F>(&self, name: &str, f: F)where
F: FnMut(&ComponentInstance),
fn with_all_components<F>(&self, f: F)
fn run(&mut self) -> Result<(), Error>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.