#[repr(transparent)]pub struct GptPartitionAttributes(pub U64Le);
Expand description
Partition attribute bits.
Tuple Fields§
§0: U64Le
Implementations§
Source§impl GptPartitionAttributes
impl GptPartitionAttributes
Sourcepub const REQUIRED_PARTITION_BIT: u8 = 0u8
pub const REQUIRED_PARTITION_BIT: u8 = 0u8
If set, bit 0
indicates the partition is required for the
platform to function.
Sourcepub const NO_BLOCK_IO_PROTOCOL_BIT: u8 = 1u8
pub const NO_BLOCK_IO_PROTOCOL_BIT: u8 = 1u8
If set, bit 1
tells the firmware not to provide
EFI_BLOCK_IO_PROTOCOL
for this partition.
Sourcepub const LEGACY_BIOS_BOOTABLE_BIT: u8 = 2u8
pub const LEGACY_BIOS_BOOTABLE_BIT: u8 = 2u8
If set, bit 2
indicates to specialized software on legacy BIOS
systems that the partition may be bootable. This bit is ignored
by UEFI boot loaders.
Sourcepub fn required_partition(self) -> bool
pub fn required_partition(self) -> bool
Get the REQUIRED_PARTITION_BIT
attribute value.
Sourcepub fn update_required_partition(&mut self, required: bool)
pub fn update_required_partition(&mut self, required: bool)
Update the REQUIRED_PARTITION_BIT
attribute value.
Sourcepub fn no_block_io_protocol(self) -> bool
pub fn no_block_io_protocol(self) -> bool
Get the NO_BLOCK_IO_PROTOCOL_BIT
attribute value.
Sourcepub fn update_no_block_io_protocol(&mut self, no_block_io_protocol: bool)
pub fn update_no_block_io_protocol(&mut self, no_block_io_protocol: bool)
Update the NO_BLOCK_IO_PROTOCOL_BIT
attribute value.
Sourcepub fn legacy_bios_bootable(self) -> bool
pub fn legacy_bios_bootable(self) -> bool
Get the LEGACY_BIOS_BOOTABLE_BIT
attribute value.
Sourcepub fn update_legacy_bios_bootable(&mut self, legacy_bios_bootable: bool)
pub fn update_legacy_bios_bootable(&mut self, legacy_bios_bootable: bool)
Update the LEGACY_BIOS_BOOTABLE_BIT
attribute value.
Sourcepub fn type_specific_attributes(self) -> U16Le
pub fn type_specific_attributes(self) -> U16Le
Bits 48..=63
represented as a U16Le
. These bits are
reserved for custom use by the partition type, so their meaning
depends on GptPartitionEntry::partition_type_guid
.
Sourcepub fn update_type_specific_attributes(&mut self, attrs: U16Le)
pub fn update_type_specific_attributes(&mut self, attrs: U16Le)
Set bits 48..=63
. These bits are reserved for custom use by
the partition type, so their meaning depends on
GptPartitionEntry::partition_type_guid
.
Trait Implementations§
Source§impl Clone for GptPartitionAttributes
impl Clone for GptPartitionAttributes
Source§fn clone(&self) -> GptPartitionAttributes
fn clone(&self) -> GptPartitionAttributes
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for GptPartitionAttributes
impl Debug for GptPartitionAttributes
Source§impl Default for GptPartitionAttributes
impl Default for GptPartitionAttributes
Source§fn default() -> GptPartitionAttributes
fn default() -> GptPartitionAttributes
Source§impl Display for GptPartitionAttributes
impl Display for GptPartitionAttributes
Source§impl Hash for GptPartitionAttributes
impl Hash for GptPartitionAttributes
Source§impl Ord for GptPartitionAttributes
impl Ord for GptPartitionAttributes
Source§fn cmp(&self, other: &GptPartitionAttributes) -> Ordering
fn cmp(&self, other: &GptPartitionAttributes) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for GptPartitionAttributes
impl PartialEq for GptPartitionAttributes
Source§impl PartialOrd for GptPartitionAttributes
impl PartialOrd for GptPartitionAttributes
impl Copy for GptPartitionAttributes
impl Eq for GptPartitionAttributes
impl Pod for GptPartitionAttributes
impl StructuralPartialEq for GptPartitionAttributes
Auto Trait Implementations§
impl Freeze for GptPartitionAttributes
impl RefUnwindSafe for GptPartitionAttributes
impl Send for GptPartitionAttributes
impl Sync for GptPartitionAttributes
impl Unpin for GptPartitionAttributes
impl UnwindSafe for GptPartitionAttributes
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
Source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self
must have the same layout as the specified Bits
except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern
.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
bits
as &Self
.