pub struct ElfSection<'a> { /* private fields */ }
Expand description
A single generic ELF Section.
Implementations§
Source§impl ElfSection<'_>
impl ElfSection<'_>
Sourcepub fn section_type(&self) -> ElfSectionType
pub fn section_type(&self) -> ElfSectionType
Get the section type as an ElfSectionType
enum variant.
Sourcepub fn section_type_raw(&self) -> u32
pub fn section_type_raw(&self) -> u32
Get the “raw” section type as a u32
Sourcepub fn start_address(&self) -> u64
pub fn start_address(&self) -> u64
Get the physical start address of the section.
Sourcepub fn end_address(&self) -> u64
pub fn end_address(&self) -> u64
Get the physical end address of the section.
This is the same as doing section.start_address() + section.size()
Sourcepub fn addralign(&self) -> u64
pub fn addralign(&self) -> u64
Get the section’s address alignment constraints.
That is, the value of start_address
must be congruent to 0,
modulo the value of addrlign
. Currently, only 0 and positive
integral powers of two are allowed. Values 0 and 1 mean the section has no
alignment constraints.
Sourcepub fn flags(&self) -> ElfSectionFlags
pub fn flags(&self) -> ElfSectionFlags
Get the section’s flags.
Sourcepub fn is_allocated(&self) -> bool
pub fn is_allocated(&self) -> bool
Check if the ALLOCATED
flag is set in the section flags.
Trait Implementations§
Source§impl<'a> Clone for ElfSection<'a>
impl<'a> Clone for ElfSection<'a>
Source§fn clone(&self) -> ElfSection<'a>
fn clone(&self) -> ElfSection<'a>
Returns a copy of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ElfSection<'_>
impl Debug for ElfSection<'_>
Source§impl<'a> Hash for ElfSection<'a>
impl<'a> Hash for ElfSection<'a>
Source§impl<'a> Ord for ElfSection<'a>
impl<'a> Ord for ElfSection<'a>
Source§impl<'a> PartialEq for ElfSection<'a>
impl<'a> PartialEq for ElfSection<'a>
Source§impl<'a> PartialOrd for ElfSection<'a>
impl<'a> PartialOrd for ElfSection<'a>
Source§fn partial_cmp(&self, other: &ElfSection<'a>) -> Option<Ordering>
fn partial_cmp(&self, other: &ElfSection<'a>) -> Option<Ordering>
impl<'a> Copy for ElfSection<'a>
impl<'a> Eq for ElfSection<'a>
impl<'a> StructuralPartialEq for ElfSection<'a>
Auto Trait Implementations§
impl<'a> Freeze for ElfSection<'a>
impl<'a> RefUnwindSafe for ElfSection<'a>
impl<'a> !Send for ElfSection<'a>
impl<'a> !Sync for ElfSection<'a>
impl<'a> Unpin for ElfSection<'a>
impl<'a> UnwindSafe for ElfSection<'a>
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dst: *mut u8)
unsafe fn clone_to_uninit(&self, dst: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)