pub struct CentralityCalculator { /* private fields */ }Expand description
Main centrality calculator with heuristics integration
Implementations§
Source§impl CentralityCalculator
impl CentralityCalculator
Sourcepub fn new() -> Result<CentralityCalculator, ScribeError>
pub fn new() -> Result<CentralityCalculator, ScribeError>
Create a new centrality calculator with default configuration
Sourcepub fn with_config(
config: CentralityConfig,
) -> Result<CentralityCalculator, ScribeError>
pub fn with_config( config: CentralityConfig, ) -> Result<CentralityCalculator, ScribeError>
Create with custom configuration
Sourcepub fn for_large_codebases() -> Result<CentralityCalculator, ScribeError>
pub fn for_large_codebases() -> Result<CentralityCalculator, ScribeError>
Create optimized for large codebases
Sourcepub fn calculate_centrality<T>(
&self,
scan_results: &[T],
) -> Result<CentralityResults, ScribeError>where
T: ScanResult + Sync,
pub fn calculate_centrality<T>(
&self,
scan_results: &[T],
) -> Result<CentralityResults, ScribeError>where
T: ScanResult + Sync,
Calculate centrality scores for a collection of scan results
Sourcepub fn integrate_with_heuristics(
&self,
centrality_results: &CentralityResults,
heuristic_scores: &HashMap<String, f64>,
) -> Result<HashMap<String, f64>, ScribeError>
pub fn integrate_with_heuristics( &self, centrality_results: &CentralityResults, heuristic_scores: &HashMap<String, f64>, ) -> Result<HashMap<String, f64>, ScribeError>
Integrate centrality scores with existing heuristic scores
Trait Implementations§
Source§impl Debug for CentralityCalculator
impl Debug for CentralityCalculator
Source§impl Default for CentralityCalculator
impl Default for CentralityCalculator
Source§fn default() -> CentralityCalculator
fn default() -> CentralityCalculator
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CentralityCalculator
impl RefUnwindSafe for CentralityCalculator
impl Send for CentralityCalculator
impl Sync for CentralityCalculator
impl Unpin for CentralityCalculator
impl UnwindSafe for CentralityCalculator
Blanket Implementations§
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
Mutably borrows from an owned value. Read more
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>
Converts
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>
Converts
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