pub trait Entity {
// Provided methods
fn parse(&mut self, source: &Path) -> Result<()> { ... }
fn render(
&self,
env: &Environment<'_>,
context: Context,
dest: &Path,
) -> Result<()> { ... }
}Expand description
A trait represents the entity of config file.
An entity contains two stage:
- parse, the stage the entity to parse its attribute, such as parse markdown to html.
- render, the stage to render the entity to html file.
Entity has default empty implementations for both methods.