pub struct AnalysisModule { /* private fields */ }Expand description
Analysis module for combined operations.
Implementations§
Source§impl AnalysisModule
impl AnalysisModule
Sourcepub fn new(
graph: GraphModule,
cfg: CfgModule,
edit: EditModule,
search: SearchModule,
) -> Self
pub fn new( graph: GraphModule, cfg: CfgModule, edit: EditModule, search: SearchModule, ) -> Self
Create a new AnalysisModule.
Sourcepub fn graph(&self) -> &GraphModule
pub fn graph(&self) -> &GraphModule
Get the graph module
Sourcepub fn search(&self) -> &SearchModule
pub fn search(&self) -> &SearchModule
Get the search module
Sourcepub fn edit(&self) -> &EditModule
pub fn edit(&self) -> &EditModule
Get the edit module
Sourcepub async fn impact_analysis(&self, symbol: &str) -> Result<ImpactData>
pub async fn impact_analysis(&self, symbol: &str) -> Result<ImpactData>
Analyze the impact of changing a symbol.
Returns detailed impact data including references, calls, and impact score.
Sourcepub async fn analyze_impact(&self, symbol_name: &str) -> Result<ImpactAnalysis>
pub async fn analyze_impact(&self, symbol_name: &str) -> Result<ImpactAnalysis>
Analyze the impact of changing a symbol.
Returns all symbols that would be affected by modifying the given symbol.
Sourcepub async fn dead_code_detection(&self) -> Result<Vec<Symbol>>
pub async fn dead_code_detection(&self) -> Result<Vec<Symbol>>
Find dead code in the codebase.
Returns symbols that are defined but never called/referenced.
Sourcepub async fn deep_impact_analysis(
&self,
symbol_name: &str,
depth: u32,
) -> Result<Vec<ImpactedSymbol>>
pub async fn deep_impact_analysis( &self, symbol_name: &str, depth: u32, ) -> Result<Vec<ImpactedSymbol>>
Perform deep impact analysis with k-hop traversal.
Returns all symbols within k hops of the target symbol.
Sourcepub async fn find_dead_code(&self) -> Result<Vec<Symbol>>
pub async fn find_dead_code(&self) -> Result<Vec<Symbol>>
Find dead code in the codebase.
Returns symbols that are defined but never called/referenced.
Sourcepub async fn reference_chain(&self, symbol: &str) -> Result<Vec<Symbol>>
pub async fn reference_chain(&self, symbol: &str) -> Result<Vec<Symbol>>
Trace the reference chain from a symbol.
Returns an ordered list showing how symbols reference each other.
Sourcepub async fn call_chain(&self, symbol: &str) -> Result<Vec<Symbol>>
pub async fn call_chain(&self, symbol: &str) -> Result<Vec<Symbol>>
Trace all callers to a function.
Returns an ordered list of calling symbols.
Sourcepub async fn benchmarks(&self) -> Result<BenchmarkResults>
pub async fn benchmarks(&self) -> Result<BenchmarkResults>
Run performance benchmarks for key operations.
Returns timing data for each operation type.
Sourcepub async fn complexity_metrics(
&self,
_symbol_name: &str,
) -> Result<ComplexityMetrics>
pub async fn complexity_metrics( &self, _symbol_name: &str, ) -> Result<ComplexityMetrics>
Calculate complexity metrics for a function.
Returns cyclomatic complexity and other metrics. Uses source-based estimation as CFG extraction is done during indexing.
Sourcepub fn analyze_source_complexity(&self, source: &str) -> ComplexityMetrics
pub fn analyze_source_complexity(&self, source: &str) -> ComplexityMetrics
Calculate complexity from source code directly.
Sourcepub async fn cross_references(
&self,
symbol_name: &str,
) -> Result<CrossReferences>
pub async fn cross_references( &self, symbol_name: &str, ) -> Result<CrossReferences>
Get cross-references for a symbol.
Returns both callers (incoming) and callees (outgoing).
Sourcepub async fn module_dependencies(&self) -> Result<Vec<ModuleDependency>>
pub async fn module_dependencies(&self) -> Result<Vec<ModuleDependency>>
Analyze module dependencies.
Returns dependencies between modules in the codebase.
Auto Trait Implementations§
impl Freeze for AnalysisModule
impl RefUnwindSafe for AnalysisModule
impl Send for AnalysisModule
impl Sync for AnalysisModule
impl Unpin for AnalysisModule
impl UnsafeUnpin for AnalysisModule
impl UnwindSafe for AnalysisModule
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
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