pub struct ProcessRunner { /* private fields */ }Expand description
A running or completed process
Implementations§
Source§impl ProcessRunner
impl ProcessRunner
Sourcepub fn new(command: impl Into<String>, options: RunOptions) -> Self
pub fn new(command: impl Into<String>, options: RunOptions) -> Self
Create a new process runner
Sourcepub async fn run(&mut self) -> Result<CommandResult>
pub async fn run(&mut self) -> Result<CommandResult>
Run the process to completion
Sourcepub fn is_finished(&self) -> bool
pub fn is_finished(&self) -> bool
Check if the process is finished
Sourcepub fn result(&self) -> Option<&CommandResult>
pub fn result(&self) -> Option<&CommandResult>
Get the result if available
Sourcepub fn options(&self) -> &RunOptions
pub fn options(&self) -> &RunOptions
Get the options
Trait Implementations§
Source§impl IntoStream for ProcessRunner
impl IntoStream for ProcessRunner
Source§fn into_stream(self) -> OutputStream
fn into_stream(self) -> OutputStream
Convert into an output stream
Source§impl PipelineExt for ProcessRunner
impl PipelineExt for ProcessRunner
Auto Trait Implementations§
impl !RefUnwindSafe for ProcessRunner
impl !UnwindSafe for ProcessRunner
impl Freeze for ProcessRunner
impl Send for ProcessRunner
impl Sync for ProcessRunner
impl Unpin for ProcessRunner
impl UnsafeUnpin for ProcessRunner
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
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>
Converts
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>
Converts
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