pub struct KillChildOnDrop {
pub command: Command,
/* private fields */
}Fields§
§command: CommandImplementations§
Source§impl KillChildOnDrop
impl KillChildOnDrop
Sourcepub fn new(command: Command) -> Self
pub fn new(command: Command) -> Self
Creates a new KillChildOnDrop with the default ChildKillMode: ChildKillMode::SIGKILL.
Sourcepub fn with_kill_mode(command: Command, kill_mode: ChildKillMode) -> Self
pub fn with_kill_mode(command: Command, kill_mode: ChildKillMode) -> Self
Creates a new KillChildOnDrop with the specified ChildKillMode.
After sending the appropriate termination signal, the process will wait for termination. See the documentation for the relevant ChildKillMode for details.
pub fn spawn(&mut self) -> Result<&mut Self>
pub fn try_wait(&mut self) -> Result<Option<ExitStatus>>
pub fn kill(&mut self) -> Result<()>
pub fn request_terminate(&mut self) -> Result<()>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for KillChildOnDrop
impl !RefUnwindSafe for KillChildOnDrop
impl Send for KillChildOnDrop
impl Sync for KillChildOnDrop
impl Unpin for KillChildOnDrop
impl !UnwindSafe for KillChildOnDrop
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