pub trait IKernel<W: IWindow, I: IUi<EventInput = W::EventType>, G: IGameLogic<EventInput = I::EventInputFiltered>, R: IRenderer<EventRender = G::EventRender>>:
AsMut<W>
+ AsMut<I>
+ AsMut<G>
+ AsMut<R>where
I::EventInputFiltered: Debug,{
// Required method
fn new() -> Result<Self, &'static str>
where Self: Sized;
// Provided methods
fn new_with<F>(f: F) -> Result<Self, &'static str>
where F: FnOnce() -> Result<Self, &'static str>,
Self: Sized { ... }
fn init_hook(&mut self) -> Result<(), &'static str> { ... }
fn deinit_hook(&mut self) -> Result<(), &'static str> { ... }
fn run(&mut self) -> Result<(), &'static str> { ... }
}
Required Methods§
Provided Methods§
fn new_with<F>(f: F) -> Result<Self, &'static str>
fn init_hook(&mut self) -> Result<(), &'static str>
fn deinit_hook(&mut self) -> Result<(), &'static str>
Implementors§
impl<GameLogic> IKernel<WinGlutin, XformInput, GameLogic, Renderer> for Kernel<GameLogic>where
GameLogic: IGameLogic<EventInput = <XformInput as IUi>::EventInputFiltered, EventRender = <Renderer as IRenderer>::EventRender>,
<GameLogic as IGameLogic>::RenderObj: Into<Vec<<GameLogic as IGameLogic>::EventRender>>,
use default implementation for run method