Struct partition_identity::PartitionIdentifiers
source · [−]pub struct PartitionIdentifiers {
pub id: Option<String>,
pub label: Option<String>,
pub part_label: Option<String>,
pub part_uuid: Option<String>,
pub path: Option<String>,
pub uuid: Option<String>,
}
Expand description
A collection of all discoverable identifiers for a partition.
Fields
id: Option<String>
label: Option<String>
part_label: Option<String>
part_uuid: Option<String>
path: Option<String>
uuid: Option<String>
Implementations
sourceimpl PartitionIdentifiers
impl PartitionIdentifiers
sourcepub fn from_path<P: AsRef<Path>>(path: P) -> PartitionIdentifiers
pub fn from_path<P: AsRef<Path>>(path: P) -> PartitionIdentifiers
Fetches all discoverable identifiers for a partition by the path to that partition.
sourcepub fn matches(&self, id: &PartitionID) -> bool
pub fn matches(&self, id: &PartitionID) -> bool
Checks if the given identity matches one of the available identifiers.
Trait Implementations
sourceimpl Clone for PartitionIdentifiers
impl Clone for PartitionIdentifiers
sourcefn clone(&self) -> PartitionIdentifiers
fn clone(&self) -> PartitionIdentifiers
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for PartitionIdentifiers
impl Debug for PartitionIdentifiers
sourceimpl Default for PartitionIdentifiers
impl Default for PartitionIdentifiers
sourcefn default() -> PartitionIdentifiers
fn default() -> PartitionIdentifiers
Returns the “default value” for a type. Read more
sourceimpl Hash for PartitionIdentifiers
impl Hash for PartitionIdentifiers
sourceimpl PartialEq<PartitionIdentifiers> for PartitionIdentifiers
impl PartialEq<PartitionIdentifiers> for PartitionIdentifiers
sourcefn eq(&self, other: &PartitionIdentifiers) -> bool
fn eq(&self, other: &PartitionIdentifiers) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &PartitionIdentifiers) -> bool
fn ne(&self, other: &PartitionIdentifiers) -> bool
This method tests for !=
.
impl StructuralPartialEq for PartitionIdentifiers
Auto Trait Implementations
impl RefUnwindSafe for PartitionIdentifiers
impl Send for PartitionIdentifiers
impl Sync for PartitionIdentifiers
impl Unpin for PartitionIdentifiers
impl UnwindSafe for PartitionIdentifiers
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more