pub struct ProcessKillGuard(pub OwnedProcess);Available on Windows only.
Expand description
A guard wrapping a OwnedProcess that will be automatically killed on drop.
Tuple Fields§
§0: OwnedProcessMethods from Deref<Target = OwnedProcess>§
Sourcepub unsafe fn borrowed_static(&self) -> BorrowedProcess<'static>
pub unsafe fn borrowed_static(&self) -> BorrowedProcess<'static>
Returns a borrowed instance of this process that lives for 'static.
§Safety
- This method is unsafe as the returned instance can outlive the owned instance, thus the caller must guarantee that the owned instance outlives the returned instance.
Trait Implementations§
Source§impl AsMut<OwnedProcess> for ProcessKillGuard
impl AsMut<OwnedProcess> for ProcessKillGuard
Source§fn as_mut(&mut self) -> &mut OwnedProcess
fn as_mut(&mut self) -> &mut OwnedProcess
Converts this type into a mutable reference of the (usually inferred) input type.
Source§impl AsRef<OwnedProcess> for ProcessKillGuard
impl AsRef<OwnedProcess> for ProcessKillGuard
Source§fn as_ref(&self) -> &OwnedProcess
fn as_ref(&self) -> &OwnedProcess
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl Borrow<OwnedProcess> for ProcessKillGuard
impl Borrow<OwnedProcess> for ProcessKillGuard
Source§fn borrow(&self) -> &OwnedProcess
fn borrow(&self) -> &OwnedProcess
Immutably borrows from an owned value. Read more
Source§impl BorrowMut<OwnedProcess> for ProcessKillGuard
impl BorrowMut<OwnedProcess> for ProcessKillGuard
Source§fn borrow_mut(&mut self) -> &mut OwnedProcess
fn borrow_mut(&mut self) -> &mut OwnedProcess
Mutably borrows from an owned value. Read more
Source§impl Debug for ProcessKillGuard
impl Debug for ProcessKillGuard
Source§impl Deref for ProcessKillGuard
impl Deref for ProcessKillGuard
Source§impl DerefMut for ProcessKillGuard
impl DerefMut for ProcessKillGuard
Source§impl Drop for ProcessKillGuard
impl Drop for ProcessKillGuard
Auto Trait Implementations§
impl Freeze for ProcessKillGuard
impl RefUnwindSafe for ProcessKillGuard
impl Send for ProcessKillGuard
impl Sync for ProcessKillGuard
impl Unpin for ProcessKillGuard
impl UnsafeUnpin for ProcessKillGuard
impl UnwindSafe for ProcessKillGuard
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