Struct libblkid_rs::BlkidProbe [−][src]
pub struct BlkidProbe(_);
Expand description
A structure for probing block devices.
Implementations
Create a new probe from a filename.
Reset and free all buffers used in the probe.
Hide a memory range in the probe from the next do_probe
call.
pub fn set_device(
&mut self,
fd: RawFd,
offset: blkid_loff_t,
size: blkid_loff_t
) -> Result<()>
pub fn set_device(
&mut self,
fd: RawFd,
offset: blkid_loff_t,
size: blkid_loff_t
) -> Result<()>
Assign the device to the probe control structure.
Get the device number associated with the probe device.
Get the device number of the whole disk
Check if the given device is an entire disk (instead of a partition or something similar)
Get the size of of a device.
Get the offset of a probing area of a device.
Get the sector size of the attached device.
Enable superblock probing.
Set the superblock probing flags.
Reset the superblock probing filter.
Invert the superblock probing filter.
Filter superblock types based on the provided flags and name.
pub fn filter_superblock_usage(
&mut self,
flag: BlkidFltr,
usage: BlkidUsageFlags
) -> Result<()>
pub fn filter_superblock_usage(
&mut self,
flag: BlkidFltr,
usage: BlkidUsageFlags
) -> Result<()>
Filter devices based on the usages specified in the usage
parameter.
Enable topology probing.
Get the blkid topology of devices.
The topology will be overwritten with each call to this method per the
libblkid documentation. To use multiple topologies simultaneously,
you must use multiple BlkidProbe
structs.
Enable partition probing.
Reset the partition filter.
Invert the partition filter.
Probe for partitions using the specified partition types.
This method can either probe for partitions with partition types specified
in names
or only for partition types not found in names
.
Get list of probed partitions.
Probe for signatures at the tag level (TAG=VALUE
). Superblocks will
be probed by default. This method calls only one function call at a time
and should be called in a loop to get results from all probing chains.
Probes all enabled chains and checks for ambiguous results.
Same as do_safeprobe
but does not check for collisions.
Number of values in probe
Get the tag and value of an entry by the index in the range
0..(self.numof_values())
.
Get the value for a tag with the given name.
Check whether the given name exists in a probe.
Set request flags.