pub trait ImageSymbol: Debug + Pod {
Show 16 methods
    // Required methods
    fn raw_name(&self) -> &[u8; 8];
    fn value(&self) -> u32;
    fn section_number(&self) -> i32;
    fn typ(&self) -> u16;
    fn storage_class(&self) -> u8;
    fn number_of_aux_symbols(&self) -> u8;
    // Provided methods
    fn name<'data, R: ReadRef<'data>>(
        &'data self,
        strings: StringTable<'data, R>,
    ) -> Result<&'data [u8]> { ... }
    fn address(
        &self,
        image_base: u64,
        sections: &SectionTable<'_>,
    ) -> Result<Option<u64>> { ... }
    fn section(&self) -> Option<SectionIndex> { ... }
    fn is_definition(&self) -> bool { ... }
    fn has_aux_file_name(&self) -> bool { ... }
    fn has_aux_function(&self) -> bool { ... }
    fn has_aux_section(&self) -> bool { ... }
    fn has_aux_weak_external(&self) -> bool { ... }
    fn base_type(&self) -> u16 { ... }
    fn derived_type(&self) -> u16 { ... }
}Expand description
A trait for generic access to pe::ImageSymbol and pe::ImageSymbolEx.
Required Methods§
fn raw_name(&self) -> &[u8; 8]
fn value(&self) -> u32
fn section_number(&self) -> i32
fn typ(&self) -> u16
fn storage_class(&self) -> u8
fn number_of_aux_symbols(&self) -> u8
Provided Methods§
Sourcefn name<'data, R: ReadRef<'data>>(
    &'data self,
    strings: StringTable<'data, R>,
) -> Result<&'data [u8]>
 
fn name<'data, R: ReadRef<'data>>( &'data self, strings: StringTable<'data, R>, ) -> Result<&'data [u8]>
Parse a COFF symbol name.
strings must be the string table used for symbol names.
Sourcefn address(
    &self,
    image_base: u64,
    sections: &SectionTable<'_>,
) -> Result<Option<u64>>
 
fn address( &self, image_base: u64, sections: &SectionTable<'_>, ) -> Result<Option<u64>>
Return the symbol address.
This takes into account the image base and the section address, and only returns an address for symbols that have an address.
Sourcefn section(&self) -> Option<SectionIndex>
 
fn section(&self) -> Option<SectionIndex>
Return the section index for the 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 has_aux_file_name(&self) -> bool
 
fn has_aux_file_name(&self) -> bool
Return true if the symbol has an auxiliary file name.
Sourcefn has_aux_function(&self) -> bool
 
fn has_aux_function(&self) -> bool
Return true if the symbol has an auxiliary function symbol.
Sourcefn has_aux_section(&self) -> bool
 
fn has_aux_section(&self) -> bool
Return true if the symbol has an auxiliary section symbol.
Sourcefn has_aux_weak_external(&self) -> bool
 
fn has_aux_weak_external(&self) -> bool
Return true if the symbol has an auxiliary weak external symbol.
fn base_type(&self) -> u16
fn derived_type(&self) -> u16
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.