Skip to main content

Analyzer

Trait Analyzer 

Source
pub trait Analyzer {
    // Required methods
    fn name(&self) -> &str;
    fn analyze(&self, ctx: &AnalysisContext) -> Vec<Finding>;
}
Expand description

Trait for page analyzers.

Implement this trait to create a custom SEO analyzer. The analyzer receives page content and returns findings.

Required Methods§

Source

fn name(&self) -> &str

Get the analyzer name.

Source

fn analyze(&self, ctx: &AnalysisContext) -> Vec<Finding>

Analyze the page content and return findings.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§