Skip to main content

ProjectAdapter

Trait ProjectAdapter 

Source
pub trait ProjectAdapter: Send + Sync {
    // Required methods
    fn detect(workspace: &Path) -> bool
       where Self: Sized;
    fn name(&self) -> &str;
    fn check_commands(&self, config: &ForgeConfig) -> Vec<CheckCommand>;
    fn parse_check_output(
        &self,
        cmd: &CheckCommand,
        stdout: &str,
        stderr: &str,
        exit_code: i32,
    ) -> ParsedCheckOutput;
}
Expand description

ProjectAdapter trait — adapts Forge to specific project types.

Required Methods§

Source

fn detect(workspace: &Path) -> bool
where Self: Sized,

Source

fn name(&self) -> &str

Source

fn check_commands(&self, config: &ForgeConfig) -> Vec<CheckCommand>

Source

fn parse_check_output( &self, cmd: &CheckCommand, stdout: &str, stderr: &str, exit_code: i32, ) -> ParsedCheckOutput

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§