pub struct TemplateEngine { /* private fields */ }Expand description
Template engine for skill generation
Implementations§
Source§impl TemplateEngine
impl TemplateEngine
Sourcepub fn get_template_names(&self) -> Vec<String>
pub fn get_template_names(&self) -> Vec<String>
Get available template names
Sourcepub fn register_template(&mut self, template: SkillTemplate) -> Result<()>
pub fn register_template(&mut self, template: SkillTemplate) -> Result<()>
Register custom template
Sourcepub fn load_template_from_file(&mut self, path: &Path) -> Result<()>
pub fn load_template_from_file(&mut self, path: &Path) -> Result<()>
Load template from file
Sourcepub fn save_template_to_file(
&self,
template_name: &str,
path: &Path,
) -> Result<()>
pub fn save_template_to_file( &self, template_name: &str, path: &Path, ) -> Result<()>
Save template to file
Sourcepub fn get_template_stats(&self) -> TemplateStats
pub fn get_template_stats(&self) -> TemplateStats
Get template statistics
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TemplateEngine
impl RefUnwindSafe for TemplateEngine
impl Send for TemplateEngine
impl Sync for TemplateEngine
impl Unpin for TemplateEngine
impl UnsafeUnpin for TemplateEngine
impl UnwindSafe for TemplateEngine
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