pub trait CentralityComputer: Send + Sync {
// Required methods
fn build_dependency_graph<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
files: &'life1 [&'life2 FileInfo],
) -> Pin<Box<dyn Future<Output = Result<DependencyGraph>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
fn compute_centrality<'life0, 'life1, 'async_trait>(
&'life0 self,
graph: &'life1 DependencyGraph,
) -> Pin<Box<dyn Future<Output = Result<CentralityScores>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn supported_languages(&self) -> Vec<Language>;
fn can_analyze_file(&self, file_info: &FileInfo) -> bool;
}
Expand description
Trait for centrality computation implementations
Required Methods§
Sourcefn build_dependency_graph<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
files: &'life1 [&'life2 FileInfo],
) -> Pin<Box<dyn Future<Output = Result<DependencyGraph>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn build_dependency_graph<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
files: &'life1 [&'life2 FileInfo],
) -> Pin<Box<dyn Future<Output = Result<DependencyGraph>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Build dependency graph from files
Sourcefn compute_centrality<'life0, 'life1, 'async_trait>(
&'life0 self,
graph: &'life1 DependencyGraph,
) -> Pin<Box<dyn Future<Output = Result<CentralityScores>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn compute_centrality<'life0, 'life1, 'async_trait>(
&'life0 self,
graph: &'life1 DependencyGraph,
) -> Pin<Box<dyn Future<Output = Result<CentralityScores>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Compute PageRank centrality scores
Sourcefn supported_languages(&self) -> Vec<Language>
fn supported_languages(&self) -> Vec<Language>
Get supported languages for dependency analysis
Sourcefn can_analyze_file(&self, file_info: &FileInfo) -> bool
fn can_analyze_file(&self, file_info: &FileInfo) -> bool
Check if file can be analyzed for dependencies