pub trait HtmlPolicy {
// Required methods
fn element(&self, name: &str) -> ElementAction;
fn attribute<'v>(
&self,
element: &str,
name: &str,
value: &'v str,
) -> Option<Cow<'v, str>>;
fn destination<'u>(&self, url: &'u str, image: bool) -> Option<Cow<'u, str>>;
}Expand description
Decides what of raw HTML and link destinations gets into the rendered tree.
Required Methods§
Sourcefn element(&self, name: &str) -> ElementAction
fn element(&self, name: &str) -> ElementAction
What happens to an element of raw HTML. The name is lowercase.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".