pub struct Job { /* private fields */ }Expand description
An owned Windows Job object.
Implementations§
Source§impl Job
impl Job
Sourcepub fn from_handle(handle: OwnedHandle) -> Result<Self>
pub fn from_handle(handle: OwnedHandle) -> Result<Self>
Adopts an existing handle after verifying it is a Job handle.
§Errors
Returns an error if Job limit information cannot be queried.
Sourcepub fn duplicate(&self) -> Result<Self>
pub fn duplicate(&self) -> Result<Self>
Creates an independent duplicate of this Job handle.
§Errors
Returns the operating-system error if duplication fails.
Sourcepub fn assign(&self, child: &Child) -> Result<()>
pub fn assign(&self, child: &Child) -> Result<()>
Assigns an existing child to the Job.
§Errors
Returns an error when Windows rejects the Job assignment.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Job
impl RefUnwindSafe for Job
impl Send for Job
impl Sync for Job
impl Unpin for Job
impl UnsafeUnpin for Job
impl UnwindSafe for Job
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