pub trait DocumentStructureExtensions {
// Provided methods
fn should_process_line(
&self,
line_num: usize,
doc_structure: &DocumentStructure,
) -> bool { ... }
fn has_relevant_elements(
&self,
_ctx: &LintContext<'_>,
_doc_structure: &DocumentStructure,
) -> bool { ... }
}
Expand description
Extended rule trait methods for using the document structure
Provided Methods§
Sourcefn should_process_line(
&self,
line_num: usize,
doc_structure: &DocumentStructure,
) -> bool
fn should_process_line( &self, line_num: usize, doc_structure: &DocumentStructure, ) -> bool
Check if a rule should operate on a given line
Sourcefn has_relevant_elements(
&self,
_ctx: &LintContext<'_>,
_doc_structure: &DocumentStructure,
) -> bool
fn has_relevant_elements( &self, _ctx: &LintContext<'_>, _doc_structure: &DocumentStructure, ) -> bool
Check if content contains elements relevant to this rule