Trait cargo_culture_kit::rules::Rule[][src]

pub trait Rule: Debug {
    fn description(&self) -> &str;
fn evaluate(
        &self,
        cargo_manifest_file_path: &Path,
        verbose: bool,
        metadata: &Option<Metadata>,
        print_output: &mut Write
    ) -> RuleOutcome; }

The core trait of this crate. A Rule describes an idiom or best-practice for projects and provides a means of evaluating whether that rule of thumb is being upheld.

Required Methods

The central tenet of this Rule. Serves as a unique identifier for Rule instances, as well as a human-readable summary of what this Rule means for a given project.

Does the Rust project found at cargo_manifest_path uphold this Rule, as summarized in the description?

Pre-parsed cargo metadata may be available, and supplemental human-readable verbose content may be written to the print_output.

Implementors