pub trait Nlist: Debug + Pod {
type Word: Into<u64>;
type Endian: Endian;
// Required methods
fn n_strx(&self, endian: Self::Endian) -> u32;
fn n_type(&self) -> u8;
fn n_sect(&self) -> u8;
fn n_desc(&self, endian: Self::Endian) -> u16;
fn n_value(&self, endian: Self::Endian) -> Self::Word;
// Provided methods
fn name<'data, R: ReadRef<'data>>(
&self,
endian: Self::Endian,
strings: StringTable<'data, R>,
) -> Result<&'data [u8]> { ... }
fn is_stab(&self) -> bool { ... }
fn is_undefined(&self) -> bool { ... }
fn is_definition(&self) -> bool { ... }
fn library_ordinal(&self, endian: Self::Endian) -> u8 { ... }
}
Expand description
A trait for generic access to Nlist32
and Nlist64
.
Required Associated Types§
Required Methods§
fn n_strx(&self, endian: Self::Endian) -> u32
fn n_type(&self) -> u8
fn n_sect(&self) -> u8
fn n_desc(&self, endian: Self::Endian) -> u16
fn n_value(&self, endian: Self::Endian) -> Self::Word
Provided Methods§
fn name<'data, R: ReadRef<'data>>( &self, endian: Self::Endian, strings: StringTable<'data, R>, ) -> Result<&'data [u8]>
sourcefn is_stab(&self) -> bool
fn is_stab(&self) -> bool
Return true if this is a STAB symbol.
This determines the meaning of the n_type
field.
sourcefn is_undefined(&self) -> bool
fn is_undefined(&self) -> bool
Return true if this is an undefined symbol.
sourcefn is_definition(&self) -> bool
fn is_definition(&self) -> bool
Return true if the symbol is a definition of a function or data object.
sourcefn library_ordinal(&self, endian: Self::Endian) -> u8
fn library_ordinal(&self, endian: Self::Endian) -> u8
Return the library ordinal.
This is either a 1-based index into the dylib load commands, or a special ordinal.
Object Safety§
This trait is not object safe.