pub trait Module {
// Required methods
fn new(ctx: ModuleContext) -> Self;
fn get_ctx(&self) -> &ModuleContext;
fn description() -> ObsString;
fn name() -> ObsString;
fn author() -> ObsString;
// Provided methods
fn load(&mut self, _load_context: &mut LoadContext) -> bool { ... }
fn unload(&mut self) { ... }
fn post_load(&mut self) { ... }
}
Required Methods§
fn new(ctx: ModuleContext) -> Self
fn get_ctx(&self) -> &ModuleContext
fn description() -> ObsString
fn name() -> ObsString
Provided Methods§
fn load(&mut self, _load_context: &mut LoadContext) -> bool
fn unload(&mut self)
fn post_load(&mut self)
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.