Struct multiboot2_header::Multiboot2Header [−][src]
#[repr(transparent)]pub struct Multiboot2Header<'a> { /* fields omitted */ }Expand description
Wrapper type around a pointer to the Multiboot2 header.
The Multiboot2 header is the Multiboot2BasicHeader followed
by all tags (see crate::tags::HeaderTagType).
Use this if you get a pointer to the header and just want
to parse it. If you want to construct the type by yourself,
please look at builder::Multiboot2HeaderBuilder.
Implementations
Public constructor for this type with various validations. It panics if the address is invalid. It panics rather than returning a result, because if this fails, it is a fatal, unrecoverable error anyways and a bug in your code.
Panics
Panics if one of the following conditions is true:
addris a null-pointeraddrisn’t 8-byte aligned- the magic value of the header is not present
- the checksum field is invalid
Safety
This function may produce undefined behaviour, if the provided addr is not a valid
Multiboot2 header pointer.
Wrapper around Multiboot2BasicHeader::verify_checksum.
Wrapper around Multiboot2BasicHeader::header_magic.
Wrapper around Multiboot2BasicHeader::arch.
Wrapper around Multiboot2BasicHeader::length.
Wrapper around Multiboot2BasicHeader::checksum.
pub fn iter(&self) -> Multiboot2HeaderTagIterⓘNotable traits for Multiboot2HeaderTagIterimpl Iterator for Multiboot2HeaderTagIter type Item = *const HeaderTag;
pub fn iter(&self) -> Multiboot2HeaderTagIterⓘNotable traits for Multiboot2HeaderTagIterimpl Iterator for Multiboot2HeaderTagIter type Item = *const HeaderTag;
impl Iterator for Multiboot2HeaderTagIter type Item = *const HeaderTag;Wrapper around Multiboot2BasicHeader::tag_iter.
Wrapper around Multiboot2BasicHeader::calc_checksum.