pub struct ProcessInfo { /* private fields */ }
Expand description
Type representing information about spawned process.
Implementations§
Source§impl ProcessInfo
impl ProcessInfo
Sourcepub fn pid(&self) -> Option<u32>
pub fn pid(&self) -> Option<u32>
Retrieve information about OS-assigned process identifier. For more information see Child::id
docs.
Sourcepub fn exit_status(&self) -> Option<ExitStatus>
pub fn exit_status(&self) -> Option<ExitStatus>
Retrieve information about process exit status.
If the process has exited, then Some(status)
is returned.
If the exit status is not available at this time then None
is returned.
Sourcepub fn is_running(&self) -> bool
pub fn is_running(&self) -> bool
Check if process is still running. This is equivalent of self.exit_status().is_none()
.
Trait Implementations§
Source§impl Clone for ProcessInfo
impl Clone for ProcessInfo
Source§fn clone(&self) -> ProcessInfo
fn clone(&self) -> ProcessInfo
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ProcessInfo
impl Debug for ProcessInfo
Source§impl PartialEq for ProcessInfo
impl PartialEq for ProcessInfo
impl Eq for ProcessInfo
impl StructuralPartialEq for ProcessInfo
Auto Trait Implementations§
impl Freeze for ProcessInfo
impl RefUnwindSafe for ProcessInfo
impl Send for ProcessInfo
impl Sync for ProcessInfo
impl Unpin for ProcessInfo
impl UnwindSafe for ProcessInfo
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