Struct libcoreinst::blockdev::Disk
source · pub struct Disk { /* private fields */ }Implementations§
source§impl Disk
impl Disk
pub fn new<P: AsRef<Path>>(path: P) -> Result<Self>
pub fn mount_partition_by_label( &self, label: &str, flags: MsFlags ) -> Result<Mount>
sourcepub fn get_busy_partitions(self) -> Result<Vec<Partition>>
pub fn get_busy_partitions(self) -> Result<Vec<Partition>>
Return an empty list if we have exclusive access to the device, or a list of partitions preventing us from gaining exclusive access.
sourcepub fn get_partition_table(&self) -> Result<Box<dyn PartTable>>
pub fn get_partition_table(&self) -> Result<Box<dyn PartTable>>
Get a handle to the set of device nodes for individual partitions of the device.