pub trait Renderable: Send + Sync {
// Required methods
fn render(&self, bindings: &HashMap<String, String>) -> Result<String>;
fn name(&self) -> &str;
// Provided method
fn source(&self) -> Option<&str> { ... }
}Expand description
Trait for template rendering
Abstracts template rendering with context bindings. Implementors transform query bindings into rendered output.
Required Methods§
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".