pub trait CommandExecutor: Send + Sync {
// Required method
fn execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
command: &'life1 str,
cwd: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<ShellOutput>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait;
}Expand description
Trait for command execution strategies
Required Methods§
Sourcefn execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
command: &'life1 str,
cwd: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<ShellOutput>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn execute<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
command: &'life1 str,
cwd: &'life2 Path,
) -> Pin<Box<dyn Future<Output = Result<ShellOutput>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Execute a command in the given directory
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".