pub struct LoopControl { /* private fields */ }
Expand description
Interface to the loop control device: /dev/loop-control
.
Implementations§
Source§impl LoopControl
impl LoopControl
Sourcepub fn next_free(&self) -> Result<LoopDevice>
pub fn next_free(&self) -> Result<LoopDevice>
Finds and opens the next available loop device.
§Examples
use loopdev::LoopControl;
let lc = LoopControl::open().unwrap();
let ld = lc.next_free().unwrap();
println!("{}", ld.path().unwrap().display());
Trait Implementations§
Source§impl AsRawFd for LoopControl
impl AsRawFd for LoopControl
Source§impl Debug for LoopControl
impl Debug for LoopControl
Source§impl IntoRawFd for LoopControl
impl IntoRawFd for LoopControl
Source§fn into_raw_fd(self) -> RawFd
fn into_raw_fd(self) -> RawFd
Consumes this object, returning the raw underlying file descriptor. Read more
Auto Trait Implementations§
impl Freeze for LoopControl
impl RefUnwindSafe for LoopControl
impl Send for LoopControl
impl Sync for LoopControl
impl Unpin for LoopControl
impl UnwindSafe for LoopControl
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