Trait html5ever_ext::RcDomExt [] [src]

pub trait RcDomExt: Sized + Minify {
    fn from_file_path_verified_and_stripped_of_comments_and_processing_instructions_and_with_a_sane_doc_type<P: AsRef<Path>>(
        html_document_file_path: P
    ) -> Result<Self, HtmlError>;
fn from_file_path<P: AsRef<Path>>(file_path: P) -> Result<Self, HtmlError>;
fn verify(&self, context: &Path) -> Result<(), HtmlError>;
fn recursively_strip_nodes_of_comments_and_processing_instructions_and_create_sane_doc_type(
        &self,
        context: &Path
    ) -> Result<(), HtmlError>; }

This trait adds additional methods to a HTML DOM.

Required Methods

Creates an instance of an HTML DOM from a file path which is verified, stripped and with a sane DocType.

Creates an instance of an HTML DOM from a file path

Verify that this HTML DOM is valid.

Remove all comments and processing instructions and make the DOCTYPE a simple 'html' (for HTML 5).

Implementors