pub struct DirLock { /* private fields */ }Implementations§
Source§impl DirLock
impl DirLock
Sourcepub fn acquire(dir: &Path) -> Result<Self>
pub fn acquire(dir: &Path) -> Result<Self>
Create dir if it is missing and wait until no one else holds it.
Sourcepub fn acquire_within(dir: &Path, wait: Duration) -> Result<Self>
pub fn acquire_within(dir: &Path, wait: Duration) -> Result<Self>
DirLock::acquire that gives up after wait with a
LockTimeout, which a holder that never lets go would otherwise
turn into a wait with no end.
Auto Trait Implementations§
impl !Send for DirLock
impl Forget for DirLock
impl Freeze for DirLock
impl Move for DirLock
impl RefUnwindSafe for DirLock
impl Sync for DirLock
impl Unpin for DirLock
impl UnsafeUnpin for DirLock
impl UnwindSafe for DirLock
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