#[repr(packed(1))]pub struct Header {
pub zero_vector: [u8; 16],
pub guid: Guid,
pub length: u64,
pub signature: [u8; 4],
pub attributes: u32,
pub header_length: u16,
pub checksum: u16,
pub reserved: [u8; 3],
pub revision: u8,
}Fields§
§zero_vector: [u8; 16]§guid: Guid§length: u64§signature: [u8; 4]§attributes: u32§header_length: u16§checksum: u16§reserved: [u8; 3]§revision: u8Implementations§
Source§impl Header
impl Header
pub fn valid(&self) -> bool
pub fn attributes(&self) -> Attributes
Trait Implementations§
Source§impl Plain for Header
impl Plain for Header
fn from_bytes(bytes: &[u8]) -> Result<&Self, Error>where
Self: Sized,
fn slice_from_bytes(bytes: &[u8]) -> Result<&[Self], Error>where
Self: Sized,
fn slice_from_bytes_len(bytes: &[u8], len: usize) -> Result<&[Self], Error>where
Self: Sized,
fn from_mut_bytes(bytes: &mut [u8]) -> Result<&mut Self, Error>where
Self: Sized,
fn slice_from_mut_bytes(bytes: &mut [u8]) -> Result<&mut [Self], Error>where
Self: Sized,
fn slice_from_mut_bytes_len(
bytes: &mut [u8],
len: usize,
) -> Result<&mut [Self], Error>where
Self: Sized,
fn copy_from_bytes(&mut self, bytes: &[u8]) -> Result<(), Error>
Auto Trait Implementations§
impl Freeze for Header
impl RefUnwindSafe for Header
impl Send for Header
impl Sync for Header
impl Unpin for Header
impl UnsafeUnpin for Header
impl UnwindSafe for Header
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
Mutably borrows from an owned value. Read more