pub struct RazCore {
pub context_analyzer: Arc<ProjectAnalyzer>,
/* private fields */
}
Expand description
Main entry point for the RAZ command generation system
Fields§
§context_analyzer: Arc<ProjectAnalyzer>
Implementations§
Source§impl RazCore
impl RazCore
Sourcepub fn with_config(config: ConfigManager) -> Result<Self>
pub fn with_config(config: ConfigManager) -> Result<Self>
Create a new RAZ instance with custom configuration
Sourcepub async fn analyze_workspace(&self, path: &Path) -> Result<ProjectContext>
pub async fn analyze_workspace(&self, path: &Path) -> Result<ProjectContext>
Analyze a workspace and return project context
Sourcepub async fn generate_commands(
&self,
context: &ProjectContext,
) -> Result<Vec<Command>>
pub async fn generate_commands( &self, context: &ProjectContext, ) -> Result<Vec<Command>>
Generate commands for the given context
Sourcepub async fn execute_command(
&self,
command: &Command,
) -> Result<ExecutionResult>
pub async fn execute_command( &self, command: &Command, ) -> Result<ExecutionResult>
Execute a command
Sourcepub async fn execute_command_with_browser(
&self,
command: &Command,
browser: Option<String>,
) -> Result<ExecutionResult>
pub async fn execute_command_with_browser( &self, command: &Command, browser: Option<String>, ) -> Result<ExecutionResult>
Execute a command with browser launching support
Sourcepub fn register_provider(&mut self, provider: Box<dyn CommandProvider>)
pub fn register_provider(&mut self, provider: Box<dyn CommandProvider>)
Register a custom command provider
Sourcepub fn get_config(&self, workspace: &Path) -> EffectiveConfig
pub fn get_config(&self, workspace: &Path) -> EffectiveConfig
Get effective configuration for a workspace
Sourcepub fn get_command_override(
&self,
workspace: &Path,
key: &str,
) -> Option<CommandOverride>
pub fn get_command_override( &self, workspace: &Path, key: &str, ) -> Option<CommandOverride>
Get command override for a specific file/context
Sourcepub fn set_command_override(
&mut self,
workspace: &Path,
key: String,
override_config: CommandOverride,
) -> Result<()>
pub fn set_command_override( &mut self, workspace: &Path, key: String, override_config: CommandOverride, ) -> Result<()>
Set command override for a specific file/context
Sourcepub async fn generate_universal_commands(
&self,
file_path: &Path,
cursor: Option<Position>,
) -> Result<Vec<Command>>
pub async fn generate_universal_commands( &self, file_path: &Path, cursor: Option<Position>, ) -> Result<Vec<Command>>
Generate universal commands for any file (stateless)
Sourcepub async fn generate_universal_commands_with_options(
&self,
file_path: &Path,
cursor: Option<Position>,
force_standalone: bool,
) -> Result<Vec<Command>>
pub async fn generate_universal_commands_with_options( &self, file_path: &Path, cursor: Option<Position>, force_standalone: bool, ) -> Result<Vec<Command>>
Generate universal commands with force standalone option
Sourcepub async fn generate_universal_commands_with_override(
&self,
file_path: &Path,
cursor: Option<Position>,
override_input: &str,
) -> Result<Vec<Command>>
pub async fn generate_universal_commands_with_override( &self, file_path: &Path, cursor: Option<Position>, override_input: &str, ) -> Result<Vec<Command>>
Generate universal commands with runtime override
Sourcepub fn build_override_key(
file_path: &Path,
context: &FileExecutionContext,
cursor: Option<Position>,
) -> Option<String>
pub fn build_override_key( file_path: &Path, context: &FileExecutionContext, cursor: Option<Position>, ) -> Option<String>
Build override key from file path and context
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RazCore
impl !RefUnwindSafe for RazCore
impl Send for RazCore
impl Sync for RazCore
impl Unpin for RazCore
impl !UnwindSafe for RazCore
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