Function file_guard::lock
source · pub fn lock<T: Deref<Target = File>>(
file: T,
lock: Lock,
offset: usize,
len: usize
) -> Result<FileGuard<T>>
Expand description
Wait and claim the desired Lock
type using a byte range of a file.
The byte range does not need to exist in the underlying file.