[−][src]Enum disk_types::Sector
Used with the Disk::get_sector
method for converting a more human-readable unit
into the corresponding sector for the given disk.
Variants
The first sector in the disk where partitions should be created.
The last sector in the disk where partitions should be created.
Unit(u64)
A raw value that directly corrects to the exact number of sectors that will be used.
UnitFromEnd(u64)
Similar to the above, but subtracting from the end.
Megabyte(u64)
Rather than specifying the sector count, the user can specify the actual size in megabytes. This value will later be used to get the exact sector count based on the sector size.
MegabyteFromEnd(u64)
Similar to the above, but subtracting from the end.
Percent(u16)
The percent can be represented by specifying a value between 0 and u16::MAX, where u16::MAX is 100%.
Trait Implementations
impl Clone for Sector
[src]
impl Copy for Sector
[src]
impl Debug for Sector
[src]
impl From<u64> for Sector
[src]
impl FromStr for Sector
[src]
type Err = &'static str
The associated error which can be returned from parsing.
fn from_str(input: &str) -> Result<Self, Self::Err>
[src]
impl Hash for Sector
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
impl PartialEq<Sector> for Sector
[src]
impl StructuralPartialEq for Sector
[src]
Auto Trait Implementations
impl RefUnwindSafe for Sector
impl Send for Sector
impl Sync for Sector
impl Unpin for Sector
impl UnwindSafe for Sector
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,