pub trait BranchCheck:
Debug
+ Send
+ Sync {
// Required methods
fn name(&self) -> &str;
fn check(
&self,
ctx: &CheckGitContext,
commit: &CommitId,
) -> Result<CheckResult, Box<dyn Error>>;
}Expand description
Interface for checks which runs once for the entire branch.
This is intended for checks which do not need to check the content, but instead, look at metadata such as the author or the topology of the branch.
Required Methods§
Sourcefn check(
&self,
ctx: &CheckGitContext,
commit: &CommitId,
) -> Result<CheckResult, Box<dyn Error>>
fn check( &self, ctx: &CheckGitContext, commit: &CommitId, ) -> Result<CheckResult, Box<dyn Error>>
Run the check.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".