pub trait CourseModule: Debug + Any {
    // Required methods
    fn new(data: Arc<CourseModuleData>) -> Self
       where Self: Sized;
    fn name() -> &'static str
       where Self: Sized;
    fn as_any(&mut self) -> &mut dyn Any;
}

Required Methods§

source

fn new(data: Arc<CourseModuleData>) -> Self
where Self: Sized,

Constructs a new instance of the Module, for a specific Course

source

fn name() -> &'static str
where Self: Sized,

The name of the course module.
Needs to correspond to the id of the tab in the HTML (without the prefix: nav_course_)

source

fn as_any(&mut self) -> &mut dyn Any

Converts the Module to Any, required for downcasting back to a concrete type

Implementors§