pub trait FunctionIntelligence: Send + Sync {
// Required methods
fn family_name(&self) -> &'static str;
fn get_all_properties(&self) -> HashMap<String, FunctionProperties>;
fn has_function(&self, name: &str) -> bool;
// Provided methods
fn function_count(&self) -> usize { ... }
fn function_names(&self) -> Vec<String> { ... }
}Expand description
Core trait for mathematical function intelligence
This trait defines the essential interface that all function intelligence modules must implement, ensuring consistent behavior across the system.
§Design Principles
- Single Responsibility: Each implementation handles one function family
- Interface Segregation: Minimal, focused interface
- Dependency Inversion: Depend on abstractions, not concretions
- Open/Closed: Open for extension, closed for modification
Required Methods§
Sourcefn family_name(&self) -> &'static str
fn family_name(&self) -> &'static str
Get the name of this function family
Sourcefn get_all_properties(&self) -> HashMap<String, FunctionProperties>
fn get_all_properties(&self) -> HashMap<String, FunctionProperties>
Get all function properties managed by this intelligence
Sourcefn has_function(&self, name: &str) -> bool
fn has_function(&self, name: &str) -> bool
Check if this intelligence manages a specific function
Provided Methods§
Sourcefn function_count(&self) -> usize
fn function_count(&self) -> usize
Get the number of functions managed by this intelligence
Sourcefn function_names(&self) -> Vec<String>
fn function_names(&self) -> Vec<String>
Get function names managed by this intelligence