Struct HealthScanCtx
pub struct HealthScanCtx {
pub complexity_source: String,
pub imports_source: String,
pub history_cutoff: Option<String>,
pub include_clones: bool,
pub clone_source: CloneSource,
}Expand description
What revision / sources a code-health scan runs against. head() resolves
to today’s HEAD tables so existing behaviour is byte-identical.
Fields§
§complexity_source: StringComplexity source table (HEAD: "complexity_metrics").
imports_source: StringImports source table for god-class fan-in/out (HEAD: "imports").
history_cutoff: Option<String>When Some(ts), history terms (churn, author, coupling) are limited to
commits.date <= ts.
include_clones: boolInclude the clone/DRY biomarker (true at HEAD; false at a historical rev where clone detection is unavailable).
clone_source: CloneSourceWhich surface the DRY biomarker counts clones from (ignored when
include_clones is false).
Implementations§
§impl HealthScanCtx
impl HealthScanCtx
pub fn head() -> Self
pub fn head() -> Self
The HEAD scan — every source resolves to today’s table, DRY included.
Clones are counted from the working tree, matching codelore check;
the gate baseline overrides clone_source to
CloneSource::Head.
pub fn head_default() -> Self
pub fn head_default() -> Self
Convenience alias for head(). Named for call-site clarity in analyses
that construct their own context rather than inheriting one from a caller.
Trait Implementations§
§impl Clone for HealthScanCtx
impl Clone for HealthScanCtx
§fn clone(&self) -> HealthScanCtx
fn clone(&self) -> HealthScanCtx
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for HealthScanCtx
impl RefUnwindSafe for HealthScanCtx
impl Send for HealthScanCtx
impl Sync for HealthScanCtx
impl Unpin for HealthScanCtx
impl UnsafeUnpin for HealthScanCtx
impl UnwindSafe for HealthScanCtx
Blanket Implementations§
impl<T> Allocation for T
impl<T> Allocation for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more